home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
OS/2 Shareware BBS: 2 BBS
/
02-BBS.zip
/
mailftp.zip
/
autoping.cmd
next >
Wrap
OS/2 REXX Batch file
|
1995-12-08
|
1KB
|
62 lines
/* REXX Script for Ftp-Sstar.Cmd */
/* heh heh heh - we'll stay connected by using ping ... */
/* The necessary REXX functions were added by pppdial.cmd */
address cmd
signal on halt
/* ihub domain name ... */
HostName = value( 'ftp.sstar.com' )
say 'Will PING to' HostName
call time('R')
do until rc = 0
if time('E') > 15 then '@exit'
call syssleep 5
'ping -dv' HostName '100 1'
end /* do */
/* We got a valid PING reply... we must be connected... */
/* Start mail. web, news, etc. */
/* we're connected... ring a bell :-) */
call beep 262, 250
call beep 294, 250
/* Start the ultimail/2 minimized... */
'@C:'
'@CD \TCPIP\UMAIL'
'START /B /MIN UMAIL.EXE'
/* start ftp fido session */
'@C:'
'@CD \TCPIP\BIN'
'START "FTP SStar" /C /WIN /F FTP-SSTAR.CMD'
/*
do until rc \= 0
delay = random( 41, 421 )
say time() 'Waiting' delay 'seconds until next ping...'
call syssleep delay
'ping' HostName '100 1'
end /* do */
exit
*/
say 'Stopping because of return code' rc 'from Ping.'
if rc = 0 then
do
call halt
end
else
exit
'exit'
halt:
say 'Auto ping stopped'
call syssleep 3
'exit'