DirFool 2.28 By Chris Lawrence DirFool (DF) is a small (7.5k) utility that, when using AmigaDOS 2.04, replaces the Dir and List commands with a single command. DF has several different operating modes and can work in a used-defined manner. Usage: DF is designed to run under Release 2.04 of AmigaDOS (the ROM version). DF will not work on earlier versions of AmigaDOS, including most of the beta/disk releases of 2.0. DF can be run through the Workbench's "Execute Command" option, or by using the CLI or Shell. To load it, use the following syntax: DF [pattern] [options] The pattern is a path and/or pattern that specifies the files you wish to list. For example, DF sys:~(#?.info) would list all of the files in your boot directory except icon files. The options are any of the following; however certain combinations will not work. COLS=n Specify number of columns to be output. Default=3. WIDE Output five columns per line, 14 character filenames. THREE Output three columns per line, 25 character filenames (default). LIST Output full information (similar to List command). Filenames are 30 characters, directories 24. A synonym is FULL. ANSI Show directories in THREE and WIDE listings in square brackets and highlighted italics (default). NOANSI Show directories in THREE and WIDE listings in square brackets. QUICK (Must be specified with LIST) Outputs only filenames; supresses header and trailer information (see below). FANCY (Must be specified with LIST) Outputs a full listing; displays the header and trailer information (default). NAME Sort by name (default). DATE Sort by date (most recent is first). A synonym is DATES. SIZE Sort by size (largest is first). SORT Sets sorting mode on (default). NOSORT Turns sorting mode off. REVERSE Reverses sort to opposite of regular sequence. FORWARD Sort in regular sequence (default). SLASH List directories with a forward slash (/) at the end of the name (softlinks are listed with a »). NOSLASH List directories within square brackets around the name (default). ICONS Include icon files in directory listing (default). NOICONS Do not include icon files in directory listings. NOFILES Only list directories in listing. NODIRS Only list files in listing. BLOCKS In full listing format, show number of blocks files occupy. In all formats, base disk usage on blocks used. BYTES In full listing format, show byte size of files. In all formats, base disk usage on total bytes used (default). Output: This command will show different output, depending on which options are used. The following gives a few examples: Work:Lang> DF WIDE Work:Lang on 15-Jun-92 at 22:56:24 [conman] [DirFool] [FTS] [GadFool] [ITextL] [KD-Freq] [ReqTools] [SASLibs] GadFool.info InterComm.info readme.first.d ReqTools.info 3077 bytes used - 19237888 bytes free on volume System2.0:System> DF COLS=3 System2.0:System on 15-Jun-92 at 22:58:34 AddMonitor AddMonitor.info BindMonitor.info CLI dfformat DiskCopy diskinfowb FixFonts Format Format-HD Format.info formatHDs Fountain.info Install-HD installHDs NoFastMem prep RexxMast Setmap 148041 bytes used - 3168768 bytes free on volume System2.0:> DF SYS:Tools/~(#?.info) LIST DATE System2.0:Tools on 15-Jun-92 at 23:03:23 Commodities ----rwed 13-Apr-92 Fed 29384 ----rwed 06-Jan-92 HDToolbox 95896 ----rwed 26-Dec-91 Enforcer 6400 ----rwed 25-Dec-91 ShowConfig 10436 ----rwed 25-Dec-91 Lacer 296 ----rwed 25-Dec-91 BRU 101832 ----rwed 25-Dec-91 MEmacs 52484 --p-rwed 25-Dec-91 CMD 7768 ----rwed 25-Dec-91 Calculator 16916 ----rwed 25-Dec-91 Colors 5616 ----rwed 25-Dec-91 KeyShow 10684 ----rwed 25-Dec-91 InitPrinter 1104 ----rwed 25-Dec-91 GraphicDump 2988 ----rwed 25-Dec-91 PrintFiles 2196 ----rwed 25-Dec-91 HDBackup.help 11573 ----rw-d 25-Dec-91 HDBackup 83248 ----rwed 25-Dec-91 IconEdit 46584 ----rwed 25-Dec-91 PrefsDrawer 532 ----rwed 09-Oct-91 KeyMapEd 67352 ----rwed 20-Jul-91 PerfMon 10044 ----rwed 28-Feb-91 FreeMap 7260 ----rwed 28-Feb-91 IE 57804 --p-rwed 09-Oct-90 628397 bytes used - 3168768 bytes free on volume Note that directories are always listed first in the listings, even if the list is not sorted. Advanced Options: DirFool also supports a few options for the advanced user, especially those that use the CLI a lot. These options can be set in two environment variables, DFMode and DateFormat. The DFMode variable can be used to set default modes for DirFool's output. All of the command line options are supported, which are then set as your defaults. These defaults can be over-ridden by using the DF command line. It is not recommended that you set a default pattern (ideally, DF without a pattern should list the current directory). DFMode can be a ENV variable (set by SETENV) or a local variable (set by SET). The DateFormat variable (a holdover from the ARP generation) is a way to use the multiple date formats supported in DOS 2.0 (but, unfortunately, not in its commands). DateFormat should be set to one of these values (example date is June 11, 1992): AmigaDOS 0 11-Jun-92 (default) International 1 92-06-11 U.S.A. 2 06-11-92 Canadian/U.K. 3 11-06-92 Other Stuff: DF will work with programs that set RNF_WILDSTAR (programs that allow the use of the asterisk (*) instead of #?), such as my StarFool program. I hope you enjoy DirFool and will find it useful. Chris Lawrence 24 Oct 1992