home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
DOS/V Power Report 1997 January
/
VPR9701B.ISO
/
ibm_os
/
csd
/
wx00001
/
cidserv.cmd
next >
Wrap
OS/2 REXX Batch file
|
1996-02-29
|
1KB
|
55 lines
/* */
trace off;
parse source . . myname;
'@echo off';
/*
* Set variables
*/
gv.copy = 'copy';
gv.unpack = 'unpack2.exe';
gv.false = 0;
gv.true = 1;
retcode = gv.false;
/*
* Erase following files after CID service
*/
gv.del_list = 'service2.cmd unpack2.exe chgattr.exe csdwprf.dll csdcmd.exe';
gv.del_list = gv.del_list 'attrib.exe os2\dll\csfinit.exe csfkill.exe';
gv.del_list = gv.del_list 'svgaid.exe csfkick.cmd xcsfkick.cmd rplserv2.cmd';
gv.del_list = gv.del_list 'csfcrc.exe csffchk.cmd xcsfinit.cmd xcsflchk.cmd';
/*
* Get environment vector
*/
rc = setlocal();
gv.source = value('csd_source',,'OS2ENVIRONMENT');
gv.target = value('csd_target',,'OS2ENVIRONMENT');
gv.boot = value('csd_boot',,'OS2ENVIRONMENT');
/*
* Set-up the environment for SERVICE facility
*/
gv.copy gv.source || '\unpack2.exe' gv.target || '\ 1>NUL 2>NUL';
gv.copy gv.source || '\csdcmd.exe' gv.target || '\ 1>NUL 2>NUL';
gv.copy gv.source || '\csdinst.exe' gv.target || '\os2\install 1>NUL 2>NUL';
gv.unpack gv.source || '\csdtools' gv.target || '\ /P 1>NUL 2>NUL';
/*
* Main execution
*/
rc = directory(gv.target);
if gv.boot <> 'A:' then retcode = xcsfkick();
else retcode = csfkick();
do ii = 1 to words(gv.del_list);
del_file = gv.target || '\' || word(gv.del_list,ii);
'del' del_file '1>NUL 2>NUL';
end;
rc = endlocal();
exit retcode;