Path: utzoo!attcan!uunet!husc6!purdue!iuvax!pwp From: pwp@iuvax.cs.indiana.edu (Paul Purdom) Newsgroups: comp.sys.atari.st Subject: Gulam question Message-ID: <56683@iuvax.cs.indiana.edu> Date: 6 Sep 90 15:08:22 GMT Sender: pwp@iuvax.cs.indiana.edu Lines: 21 In gulam the foreach command can be used to do something for each file in a directory. The if command can be used to test whether the file is a regular file a directory, etc. Is there some way to test what the extension on a file is? I don't see how to do this from reading the manual, but maybe I have overlooked something. The following (except for syntax errors) suggests what I would like to do foreach ...\i { * } if $i.arc arc -l $i ef echo $i endif endfor With a valid test for the arc extension, this file would produce a listing of the contents of all arc files and the name of all other files. (Note, it is easy to do half the job: foreach ...\i {*.arc} will get all the arc files; the hard thing is to dget the non arc ones.)