home *** CD-ROM | disk | FTP | other *** search
/ Dream 52 / Amiga_Dream_52.iso / Amiga / Workbench / Archivers / RealSize.lha / RealSize / example.script next >
AmigaDOS Script File  |  1998-01-03  |  696b  |  30 lines

  1. .key FILE/A
  2. .bra {
  3. .ket }
  4.  
  5. ; Usage: execute example.script <filename>
  6. ; Will report if file is crunched or not, and size
  7.  
  8. failat 21
  9. RealSize {FILE} >ENV:parp
  10. set RSRC $RC
  11. IF $RSRC eq 20
  12.   echo Can't size file {FILE} : $RealSizeError
  13. ELSE
  14.   IF $RSRC eq 5
  15.     echo {FILE} is not crunched, but is $parp bytes nevertheless
  16.   ELSE
  17.     echo {FILE} is $parp bytes uncrunched
  18.   ENDIF
  19. ENDIF
  20. unset RealSizeError
  21. unset RSRC
  22.  
  23. echo and the directory it's in looks like this uncrunched:
  24. list {FILE} to env:parpdir lformat %f
  25. echo >t:exeme failat 21
  26. list $parpdir files lformat "echo noline *"%-28n*" *nrealsize noline %n width=-14*necho %a" >>t:exeme
  27. execute t:exeme
  28. delete ENV:parp ENV:parpdir T:exeme QUIET
  29.  
  30.