Changeset 5718 for trunk/tools
- Timestamp:
- May 16, 2001, 3:17:03 AM (24 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/tools/bin/Exists.cmd
r3054 r5718 1 /* $Id: Exists.cmd,v 1. 1 2000-03-09 17:23:23 bird Exp $1 /* $Id: Exists.cmd,v 1.2 2001-05-16 01:17:03 bird Exp $ 2 2 * 3 * Simple rexx util which checks if a n fileexists.3 * Simple rexx util which checks if a file or directory exists. 4 4 * 5 5 * Syntax: exists.cmd <filename> 6 6 * Return code: 0 - file exists 7 * 1 - file do n't exist.7 * 1 - file doesn't exist. 8 8 * 9 * Copyright (c) 2000 knut st. osmundsen (knut.stange.osmundsen@pmsc.no)9 * Copyright (c) 2000-2001 knut st. osmundsen (knut.stange.osmundsen@mynd.no) 10 10 * 11 11 * Project Odin Software License can be found in LICENSE.TXT … … 14 14 parse arg sFile 15 15 16 if (sFile = '.' | sFile = '..') then 17 exit(0); 18 16 19 if (stream(sFile, 'c', 'query exists') = '') then 20 do /* directory ? */ 21 if (RxFuncQuery('SysFileTree') = 1) then 22 call RxFuncAdd 'SysFileTree', 'RexxUtil', 'SysFileTree'; 23 rc = SysFileTree(sFile, sDirs, 'DO'); 24 if (rc = 0 & sDirs.0 = 1) then 25 exit(0); 17 26 exit(1); 27 end 18 28 exit(0); 19 29
Note:
See TracChangeset
for help on using the changeset viewer.