; Open a dnet shell, choosing a system to log into
; open on a normal shell
; assume dnet: assigned where you have the dshrexx exe...

; hosts to rsh into... assume you have updated your rhost file so you don't have to
; send a password!! (otherwise these don't work)

set 1 LOCAL
set 2 mystra
set 3 frey
set 4 peach
set 5 SCREEN
set screen Workbench

lab top
reqask body "Choose a system to log onto" gad "$1|$2|$3|$4|$5|CANCEL" title ShellTerm var host

if $host eq 1
dnet:dshrexx 8195 0 DNETREXX "console con:0/0/640/200/$1 [port %r]/SCREEN$screen" "stty -echo\n"
endif

if $host eq 2
dnet:dshrexx 8195 0 DNETREXX "send rsh $2\n" "console con:0/0/640/200/$2 [port %r]/SCREEN$screen" "x wait 3" "send stty -echo\n"
endif

if $host eq 3
dnet:dshrexx 8195 0 DNETREXX "send rsh $3\n" "console con:0/0/640/200/$3 [port %r]/SCREEN$screen" "x wait 3" "send stty -echo\n"
endif

if $host eq 4
dnet:dshrexx 8195 0 DNETREXX "send rsh $4\n" "console con:0/0/640/200/$4 [port %r]/SCREEN$screen" "x wait 3" "send stty -echo\n"
endif


; SELECT SCREEN TO OPEN WINDOW ON
if $host eq 5
set s1 Workbench
set s2 CygnusEdScreen1
reqask body "Screen to open on" gad $s1|$s2|CANCEL title ShellTerm var dpy
if $dpy eq 1
set screen $s1
endif

if $dpy eq 2
set screen $s2
endif

skip back label top
endif

