home *** CD-ROM | disk | FTP | other *** search
/ DOS/V Power Report 1997 December / VPR9712B.ISO / Nsos2 / PLUGPKJP.EXE / sysfbkup.cmd < prev   
OS/2 REXX Batch file  |  1997-02-25  |  915b  |  41 lines

  1. /* */
  2. arg which os2path winpath windrive
  3.  
  4. which = strip(which)
  5.  
  6. if which   = '' |,
  7.    os2path = '' |,
  8.    winpath = '' |,
  9.    windrive= '' then exit 0
  10.  
  11. if left(which,1) = '9' then which = 'V4'
  12. else do
  13.   parse var which with .','which
  14.   which = strip(which)
  15.   if which = 'HALF' then which = 'HP'
  16.   else which = 'FP'
  17. end
  18.  
  19. path.O = strip(os2path)'\DLL\'
  20. path.M = strip(windrive)'\OS2\MDOS\'
  21. path.W = strip(winpath)'\SYSTEM\'
  22.  
  23. file.   = ''
  24. file.1  = 'HPFPV4 O seamless dll'
  25. file.2  = 'HPFPV4 W winsmsg  dll'
  26. file.3  = '  FPV4 W user     exe'
  27. file.4  = 'HPFP   M vwin     sys'
  28. file.5  = 'HP     W users    scr'
  29.  
  30. i = 1
  31. do while file.i <> ''
  32.   if pos( which, word(file.i,1) ) <> 0 then
  33.   do
  34.     index = word(file.i,2)
  35.     base = path.index||word(file.i,3)
  36.     if stream( base'.bak', 'c', 'query exists' ) = '' then
  37.       'copy' base'.'word(file.i,4) base'.bak'
  38.   end
  39.   i = i + 1
  40. end
  41.