home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
OS/2 Shareware BBS: 2 BBS
/
02-BBS.zip
/
zpars106.zip
/
COMPILE.CMD
next >
Wrap
OS/2 REXX Batch file
|
1996-03-03
|
3KB
|
142 lines
/* process nodelist program */
parse upper arg NowFlag
/* env.cmd holds the settings for my enviornment not found in the config.sys*/
/*call env*/
/* define global constants */
NodeList = "K:\NodeList"
NodeStore = "Store"
ProcessFlag = "False"
NewNodeFlag = "False"
BinkleyFlag = "D:\Binkley\Flags\Forcexit.1"
NICE = "i:\ubin\sp i0 "
if NowFlag = 'NOW' then ProcessFlag = 'True'
if NowFlag = 'ZPARSE' then Signal ZParse
rq = Directory(NodeList)
/* check whether RxFuncs are loaded, if not, load them */
if RxFuncQuery('SysLoadFuncs') then
do
/* load the load-function */
call RxFuncAdd 'SysLoadFuncs', 'RexxUtil', 'SysLoadFuncs'
/* load the Sys* utilities */
call SysLoadFuncs
end
/* ibmNET */
/* search for files only and return qualified pathname only */
call SysFileTree 'D:\Binkley\Inbound\ibmlist.z??', file, "FO"
/* Process ibmNET Nodelist */
If file.0 > 0 then
Do
/* erase old nodelists */
'rm ibmlist.[0123]??'
'rm FReq\ibmlist.*'
do fnum = 1 to file.0
'copy ' file.fnum NodeList
NodeFile = FILESPEC("name",file.fnum)
/* ibmNET nodelists are always ZIPped */
'unzip -o' NodeFile
'move' NodeFile 'FReq'
/*"move" NodeFile NodeStore*/
end
ProcessFlag = "True"
End
/* IMex */
/* search for files only and return qualified pathname only */
call SysFileTree 'D:\Binkley\Inbound\imexlist.a*', file, "FO"
/* Process Imex Nodelist */
If file.0 > 0 then
Do
/* erase old nodelists */
'rm imexlist.[0123]??'
'rm FReq\imexlist.*'
do fnum = 1 to file.0
"mmv -x -d" file.fnum NodeList
NodeFile = FILESPEC("name",file.fnum)
/* IMEX nodelists are always ARCed */
'arc2 xo' NodeFile
'copy' NodeFile 'FReq'
"move" NodeFile NodeStore
end
ProcessFlag = "True"
End
/* FidoNet (nodediffs) */
/* search for files only and return qualified pathname only */
call SysFileTree 'D:\Binkley\Protin\nodediff.a*', file, "FO"
/* Process Fidonet nodediff */
If file.0 > 0 then
Do
'rm FReq\nodediff.*'
do fnum = 1 to file.0
"mmv -x -d" file.fnum NodeList
NodeFile = FILESPEC("name",file.fnum)
/* FidoNet nodediffs are always ARCed */
'arc2 xo' NodeFile
'copy' NodeFile 'FReq'
'mmv -x -d' NodeFile NodeStore
/* 'squishp send FReq\'||NodeFile 'to 1:340/301 crash'*/
/* 'squishp send FReq\'||NodeFile 'to 1:340/307 crash'*/
end
ProcessFlag = "True"
NewNodeFlag = "True" /* nodelist was updated */
End
if NowFlag = 'TEST' then ProcessFlag = 'False'
if NewNodeFlag = "True" then
do
'zdiff nodelist nodediff'
if rc = 0 Then
do
'rm FReq\nodelist.zip'
'detach sp i0 zip2 -9jq FReq\NodeList nodelist.???'
end
else
do
Say "Error Processing Nodelists RC= " rc
Signal AllDone
end
end
If ProcessFlag \= 'True' Then
Signal AllDone
ZParse:
'zparse'
/* make binkleyflag and force.exit flag */
Do Until rq = "READY:"
rq = stream(BinkleyFlag, "C", "Open Write")
If rq = "READY:" then
Leave
"Delay 15 S"
End
Signal AllDone
AllDone: