1DISLOCATE(1)                General Commands Manual               DISLOCATE(1)
2
3
4

NAME

6       Dislocate - disconnect and reconnect processes
7

SYNOPSIS

9       dislocate [ program args...  ]
10

INTRODUCTION

12       Dislocate  allows  processes  to be disconnected and reconnected to the
13       terminal.  Possible uses:
14
15              ·   You can disconnect a process from a  terminal  at  work  and
16                  reconnect from home, to continue working.
17
18              ·   After  having your line be dropped due to noise, you can get
19                  back to your process  without  having  to  restart  it  from
20                  scratch.
21
22              ·   If  you  have a problem that you would like to show someone,
23                  you can set up the scenario at your  own  terminal,  discon‐
24                  nect, walk down the hall, and reconnect on another terminal.
25
26              ·   If  you are in the middle of a great game (or whatever) that
27                  does not allow you to save, and someone else kicks  you  off
28                  the terminal, you can disconnect, and reconnect later.
29

USAGE

31       When run with no arguments, Dislocate tells you about your disconnected
32       processes and lets you reconnect to one.  Otherwise, Dislocate runs the
33       named program along with any arguments.
34
35       By default, ^] is an escape that lets you talk to Dislocate itself.  At
36       that point, you can disconnect (by pressing ^D)  or  suspend  Dislocate
37       (by pressing ^Z).
38
39       Any  Tcl or Expect command is also acceptable at this point.  For exam‐
40       ple, to insert the contents of a the file /etc/motd as if you had typed
41       it, say:
42
43            send -i $out [exec cat /etc/motd]
44
45
46       To send the numbers 1 to 100 in response to the prompt "next #", say:
47
48            for {set i 0} {$i<100} {incr i} {
49                expect -i $in "next #"
50                send -i $out "$i\r"
51            }
52
53       Scripts  can  also be prepared and sourced in so that you don't have to
54       type them on the spot.
55
56       Dislocate is actually just a simple Expect script.  Feel free  to  make
57       it do what you want it to do or just use Expect directly, without going
58       through Dislocate.  Dislocate  understands  a  few  special  arguments.
59       These  should appear before any program name.  Each should be separated
60       by whitespace.  If the  arguments  themselves  takes  arguments,  these
61       should also be separated by whitespace.
62
63       The  -escape  flag  sets  the  escape to whatever follows.  The default
64       escape is ^].
65

CAVEATS

67       This program was written by the author as an exercise to show that com‐
68       municating  with  disconnected  processes is easy.  There are many fea‐
69       tures that could be added, but that is not the intent of this program.
70
71

SEE ALSO

73       Tcl(3), libexpect(3)
74       "Exploring Expect: A Tcl-Based Toolkit for Automating Interactive  Pro‐
75       grams" by Don Libes, O'Reilly and Associates, January 1995.
76

AUTHOR

78       Don Libes, National Institute of Standards and Technology
79
80
81
82                                7 October 1993                    DISLOCATE(1)
Impressum