home *** CD-ROM | disk | FTP | other *** search
/ Amiga Format 69 / af069sub.adf / ZShell21 / ZShell.doc < prev    next >
Text File  |  1994-12-11  |  77KB  |  1,716 lines

  1.  
  2.             #============================================#
  3.             #    ZSHELL V1.30 (C) 1990,91 PAUL HAYTER    #
  4.             # updated to V2.1 (C) 1993,94 MARTIN GIERICH #
  5.             #============================================#
  6.  
  7. $VER: ZShell.doc 2.1 (11.12.94)
  8. If you have used ZShell V2.0, please read CHANGES.
  9. ------------------------------------------------------------------------
  10. INTRODUCTION
  11.  
  12.     This is the ZShell version 2.1 documentation.
  13.     It is a small, fast and powerful SHELL replacement.
  14.     Have a look at FEATURES to see the advantages.
  15.     ZShell is tested with Kickstart 1.3 , 2.04 and 3.0 and should
  16.     run also with other Kickstarts. There are no special requirements.
  17.     I tried to made usage similar to AmigaDOS. If you did not
  18.     understand something, have a look at your AmigaDOS usermanual.
  19. ------------------------------------------------------------------------
  20. FEATURES
  21.  
  22.     * Freeware, no payment required.
  23.     * Usage is similar (or better) to the standard AmigaDOS shell.
  24.     * About 26K small (pure assembler code, source included).
  25.     * Supports the standard housekeeping commands which are builtin,
  26.       so no disk access is necessary.
  27.       eg. list, dir, cd, rename, makedir, delete, copy, path, info, type
  28.     * A total of 63 builtin commands.
  29.     * Starting from Workbench or CLI/Shell.
  30.     * Filenamecompletion by simply pressing TAB.
  31.     * REVIEW-buffer to see what scrolled out of the window.
  32.     * Command line editing better than KS2.0 .
  33.     * Command line history with searching.
  34.     * Command and Function key aliasing.
  35.     * Online HELP function and documentation with examples.
  36.     * Colorful output (or fast scrolling with OS3.0+, see 'CTRL -R')
  37.     * Wild Card file descriptions (*,?,~,[],|).
  38.     * DIR and LIST both sort (by default) and show filesize.
  39.     * Simple 'MORE' type text viewer.
  40.     * Has a kind of Memory-Clock with alarm.
  41.     * Makes itself resident for quicker starting and memory saving.
  42.     * Script file execution and special script commands (like IF, ASK).
  43.     * Some commands and features for debugging system/programs.
  44. ------------------------------------------------------------------------
  45. FOR THOSE WHO NEVER READ THE WHOLE DOCUMENTATION
  46.  
  47.     Start the file called ZShell from Workbench or CLI (SHELL), or even
  48.     better: Put the file ZShell in the C: directory and start the file ZSH.
  49.     Now press the HELP key. Among lots of other information you see
  50.     'TYPE HELP ? ...'. Make sure that ZShell.doc is in the current directory
  51.     and try that. You will see how to use the ONLINE HELP. Try to type
  52.     'HELP HISTORY' to see how command line editing works. Execute the
  53.     example startup file 'ZStart' or put it into the S: drawer.
  54.     Please send me your comment; my adress is at the end of this doc.
  55. ------------------------------------------------------------------------
  56. CONTENTS
  57.  
  58.     Introduction
  59.     Features
  60.     For those who never read the whole doc
  61.     Contents
  62.     Distribution
  63.     Starting ZShell
  64.     History & Command Line Editing
  65.     Executing Commands
  66.     Wild Cards
  67.     Filenamecompletion
  68.     Input/Output Redirection
  69.     Special Characters
  70.     Builtin Commands
  71.         ...
  72.     Builtin Commands for Advanced Users and Programmers
  73.         ...
  74.     Tips & Hints
  75.     Possibilities for Future Improvements
  76.     Changes
  77.     Copyright
  78.     Disclaimer
  79.     Credits
  80.     Correspondence & Bug Reports
  81. ------------------------------------------------------------------------
  82. DISTRIBUTION
  83.  
  84.     Following files belong to this document:
  85.     1) ZShell           The main executable
  86.     2) ZSH              The small starter
  87.     3) ZShell.doc       This documentation (and online help manual)
  88.     4) ReadMe           Short description
  89.     5) ZStart           An example startup script (can be put in S: )
  90.     6) ZShell.s         Source code of the main executable
  91.     7) ZSH.s            Source code of the small starter
  92.     and some icons.
  93. ------------------------------------------------------------------------
  94. STARTING ZSHELL
  95.  
  96.   * There are three ways of starting ZShell:
  97.     1. The easiest way:
  98.        Start the file called 'ZShell' from Workbench or CLI/Shell.
  99.     2. Put the file called 'ZShell' in the C: directory and
  100.        start the file called 'ZSH' from Workbench or CLI/Shell.
  101.     3. A bit complicated and only for starting from Workbench:
  102.        Make a startup script (see below) or an empty file with a PROJECT
  103.        icon. Change the default tool to 'ZSH' or 'ZShell' (better ZSH,
  104.        but put ZShell in C: ) with the right path. Doubleclicking on
  105.        this project icon will start ZShell and execute its script.
  106.        You can also shift-doubleclick a startup script with ZSH/ZShell.
  107.     (You can rename 'ZSH' as what you like, but do not rename 'ZShell').
  108.     The first way is recommended for having a quick glance at ZShell,
  109.     but if you use ZShell sometimes, the second way is better.
  110.     Why ? Because 'ZSH' is about 800 Bytes long and starts the ZShell-
  111.     resident if possible. So loading 'ZShell' is only necessary the first
  112.     time you use ZShell after booting up.
  113.   * If starting from CLI/Shell you can specify the name of a script file
  114.     (see EXECUTE) as an argument which will be executed after starting.
  115.     Precede the name with "-s". If there is no name given, ZShell will try
  116.     to execute S:ZStart . After "-w" you can specify a window-description.
  117.     eg.     ZSH -sram:hello     {will try to execute ram:hello}
  118.             ZShell              {will try to execute S:ZStart}
  119.             ZSH -sram:hello -wCON:10/10/100/100/Tach {opens this window}
  120.   * If starting from Workbench you can specify the window-description
  121.     and the startup script (default S:ZStart , see above) with ToolTypes:
  122.     eg.     WINDOW=con:20/50/400/100/Moin
  123.             SCRIPT=ram:hello
  124.     Make sure that WINDOW and SCRIPT are in capital letters.
  125.     (You can edit the ToolTypes by selecting an icon and then choosing
  126.     'Information' from the Workbench menu.)
  127.   * NOTE: ZShell and ZSH are PURE (see RESIDENT,PROTECT).
  128. ------------------------------------------------------------------------
  129. HISTORY & COMMAND LINE EDITING
  130.  
  131.     ZShell has a 1024 byte circular history buffer. It works similar
  132.     to most other shells, the NEWCON: handler in Workbench V1.3 and
  133.     the standard console handler in Kickstart 2.0+.
  134.  
  135.     You can change the edit keys with 'CTRL'. These are the default keys:
  136.     UP ARROW        - go back one line in the history buffer.
  137.     DOWN ARROW      - go forward one line in the history buffer.
  138.     SHIFT UP ARROW  - go to the 1st line in the history buffer if nothing
  139.                       was typed. Otherwise the string left of the cursor
  140.                       will be searched in history buffer. (like KS2.0+)
  141.     SHIFT DOWN ARROW- go to the last line in the history buffer, which
  142.                       should be blank.
  143.     LEFT ARROW      - move cursor left.
  144.     RIGHT ARROW     - move cursor right.
  145.     SHIFT LEFT ARROW- move cursor to left end.
  146.     SHIFT RIGHT ARROW move cursor to right end.
  147.  
  148.     CTRL S          - move cursor to start of line.
  149.     CTRL E          - move cursor to end of line.
  150.     CTRL R          - move cursor to start of previous word
  151.     CTRL T          - move cursor to start of next word
  152.  
  153.     CTRL W          - delete one word right of cursor
  154.     CTRL Q          - delete one word left of cursor
  155.     CTRL X          - delete whole line.
  156.     CTRL L          - clear the ZShell window
  157.  
  158.     TAB             - see FILENAMECOMPLETION (that is great !)
  159.     SHIFT TAB       - read review-buffer with MORE (see REVIEW).
  160.     CTRL V          - read history-buffer with MORE.
  161.     SHIFT RETURN    - like typing '^' and 'J', useful for ECHO.
  162.     ESC (Escape)    - quit ZShell like ENDCLI (I like this very much !).
  163.  
  164.     Words are delimited by space, point, slash and colon ( ./:).
  165.     Again, command line editing is similar to most shells. Backspace,
  166.     delete and return do what they are supposed to do.
  167. ------------------------------------------------------------------------
  168. EXECUTING COMMANDS
  169.  
  170.     Most commands can be aborted by depressing Control-C.
  171.     Nearly everything is case independent.
  172.     To use a disk command simply type its name after the prompt, the
  173.     same way as you would do in other shells. The first part of the input
  174.     up to the first space is interpreted as commandname. It is searched
  175.     for (in this order) :
  176.         1. in the alias list (see ALIAS)
  177.         2. in the internal (builtin) command list (see BUILTIN COMMANDS)
  178.         3. in the resident command list (see RESIDENT)
  179.         4. in the current directory (see CD)
  180.         5. in the command search path (see PATH)
  181.     and, if it is found, it is executed. The part after the first space
  182.     is taken as arguments, also called parameters. The arguments are
  183.     separated by spaces. ZShell will allow up to 25 arguments.
  184.     If the commandname is a directory, the current directory will be
  185.     changed (see CD).
  186.  
  187.     eg.     addbuffers df0: 15
  188.     'addbuffers' is the command, that will be found as a internal command.
  189.     'df0:' is the first argument. '15' is the second argument. The third
  190.     argument does not exist.
  191.  
  192.     You can avoid using an alias or an internal (builtin) command or
  193.     changing the current directory by typing a point before the
  194.     commandname (this is called 'force disk').
  195.     To abbreviate internal or resident commands put a point behind it.
  196.     If you use just a point, the current directory will be set to the
  197.     last current directory ('dir back').
  198.  
  199.     eg.     .addbuffers df0: 20
  200.     {This uses the disk command or if available the resident addbuffers}
  201.             ad. df0: 20  {uses the internal addbuffers command}
  202.             .ad. df0: 20 {if available this uses the resident addbuffers}
  203.             .            {go back to old current dir}
  204.  
  205.     BEWARE of other matching commands! The first matching will be taken!
  206.     res. can mean reset or resident, but reset will be taken !
  207.     There is no abbreviation for disk commands, take FileNameCompletion
  208.     ( CTRL-A ) instead.
  209.  
  210.     A textual error message will be displayed if an AmigaDOS error
  211.     occurs.
  212. ------------------------------------------------------------------------
  213. WILD CARDS
  214.  
  215.     ZShell supports wild card file descriptions on some commands
  216.     (DIR, LIST, DELETE, COPY, RECOPY, CTRL). Wild cards are like those
  217.     supported on MS-DOS (tm) or UNIX (tm) systems, and not the same as
  218.     the ones on AmigaDOS. So use * instead of #? .
  219.     NOTE: You can only effectively put one * character in a wild card.
  220.  
  221.     Character       Meaning
  222.        *         Match zero or more characters.
  223.        ?         Match one character.
  224.        ~         Negates the following wildcard.
  225.       [  ]       Specifies a class of characters to match.
  226.                  (One of the characters in the brackets must match)
  227.        |         Separate multiple filenames (can be wildcards)
  228.                  (One of the file descriptions separated by | must match)
  229.  
  230.     To get that just try the examples following and try it out with DIR.
  231.     eg.    list *.info      {lists all files ending in .info}
  232.            dir z*.s         {lists all files starting z, ending in .s}
  233.            delete df0:*.info   {deletes all .info files from df0:}
  234.            copy *.s ram:    {copies all .s files to ram:}
  235.            copy 1? df0:     {copies all two char files beginning with 1}
  236.            dir ~*.s         {lists all files NOT ending in .s}
  237.            list ~*.info     {lists all files except for .info files}
  238.            dir *.[co]       {lists files ending in .c or .o}
  239.            list [abcd]*     {lists files beginning with a,b,c or d}
  240.            list c:mount|version {lists the files Mount and Version}
  241.            list ram:env/a*|*b   {lists all files starting with a or
  242.                              ending with b from RAM:env (environment)}
  243.            copy ~*.info|*.bak   {copies all files NOT ending in .info
  244.                                  and NOT ending in .bak}
  245. ------------------------------------------------------------------------
  246. FILENAMECOMPLETION
  247.  
  248.     Filenamecompletion makes typing long filenames and directorynames
  249.     easier. It does not matter if you want to type it as command or as
  250.     argument. Just type some beginning characters of the desired name and
  251.     then press TAB . If there is more than one possibility that
  252.     match, it will only be completed as far as all possibilities match.
  253.     In this case type the next character then again press TAB . If a
  254.     filename was fully matched, a space after it will be inserted. If
  255.     a directoryname was fully matched, a slash (/) will be inserted after.
  256.     Maybe you do not want *.info files to be completed. This will avoid
  257.     some trouble. Use 'ctrl -c *.info' for that or see CTRL.
  258.  
  259.     For example a directory contains:
  260.         MegaEditExample
  261.         MegaEditExample.info
  262.         MegaViewer
  263.         MoreMegaFiles               {directory}
  264.  
  265.     If you want to change the current directory to MoreMegaFiles you type:
  266.         mo
  267.     then press the TAB key. You will see the full name with a slash at the
  268.     end. Just press RETURN and you changed it.
  269.     To delete MegaViewer you type:
  270.         delete me
  271.     and press TAB . You will see 'Mega'. Now type the V key and
  272.     press TAB again. You see 'delete MegaViewer '. Press RETURN and
  273.     it will be gone.
  274.     You want to start MegaEditExample. Type:
  275.         me
  276.     and press TAB. Then type E and press TAB. There is no space after the
  277.     name. This is because MegaEditExample.info also matches.
  278.     Start it by pressing RETURN.
  279. ------------------------------------------------------------------------
  280. OPTIONS
  281.  
  282.     The internal commands support only three options, because this is
  283.     easier to remember. These options start with a dash (-) .
  284.     1. -C or -CLEAR , used by AVAIL,ENDCLI,LOCATE,PATH,RESIDENT,CTRL
  285.     2. -R or -RECURSIVE , used by COPY,DELETE,LIST,RECOPY
  286.     3. -Q or -QUICK , used by DIR,LIST
  287.     So instead of typing 'dir -q' you can also type 'dir -quick'.
  288.     As nearly everything, options are also case independent.
  289. ------------------------------------------------------------------------
  290. INPUT/OUTPUT REDIRECTION
  291.  
  292.     The standard redirection operators are supported for all internal
  293.     commands, as well as disk based programs. (Redirection only affects
  294.     those programs which use the dos.library's Input() and Output()
  295.     functions.)
  296.  
  297.         >  redirect std output.
  298.         <  redirect std input.
  299.         >> append redirect output. (tacks output onto the end of file)
  300.         <> redirect input and output (not yet implemented).
  301.  
  302.     eg.    dir >ram:directory df0:c
  303.            type zshell.doc <raw:0/0/100/100/input >raw:0/0/640/100/output
  304.            sortfile things >>df0:things.log
  305. ------------------------------------------------------------------------
  306. SPECIAL CHARACTERS
  307.  
  308.     The following characters have special meanings to ZShell.
  309.  
  310.      "  "   Double quotes. Used to enclose strings with spaces.
  311.             eg "hello world".
  312.      ^n     Hat character. Prefixes a control character letter (n).
  313.             Used in ASK, ECHO, & ALIAS commands. eg ^L   <-clear screen
  314.      %n     Percent prefixes a number (0-7) to specify an optional
  315.             parameter for command aliases. Used in ALIAS command.
  316.             Can also be used to specify prompt arguments. See PROMPT.
  317.      $n     Dollar prefixes a number (0-7) and corresponds to an
  318.             optional parameter specified with %n (above).
  319.      *?~[]| Wildcard characters. * matches 0 to n characters. ? matches
  320.             one character, ~ negates the following wild card, and [ ]
  321.             surround a class of characters to match. See WILD CARDS.
  322.      \n     Backslash prefixes a special character, whose meaning you
  323.             want ignored. eg.  echo "hello \"fred\""  (hello "fred")
  324.      ;      Semi-colon seperates multiple commands on one line.
  325.             eg. cd df1:;dir
  326.      >      redirect output.
  327.      <      redirect input.
  328.      >>     redirect append output.
  329. ------------------------------------------------------------------------
  330. BUILTIN COMMANDS :
  331. ==================
  332. Following there are descriptions of the standard commands which are
  333. builtin in ZShell (and therefore need not be loaded from disk).
  334. Square brackets [] mean that the argument enclosed in is optional.
  335. A vertical bar | separates multiple possibilities, choose only one.
  336. ------------------------------------------------------------------------
  337. ADDBUFFERS drive number_of_buffers
  338.  
  339.     * ADDBUFFERS increases disk access speed on the specified drive by
  340.       adding a number of sector cache buffers. Each additional buffer
  341.       reduces memory by about 560 bytes. Generally, 25-30 buffers per
  342.       floppy drive is optimal.
  343.  
  344.     eg.     addbuffers df0: 25
  345.             addbuffers df1: 30
  346. ------------------------------------------------------------------------
  347. ALIAS [variable] [definition]
  348.  
  349.     * ALIAS assigns a variable name to a definition. The variable name
  350.       can be up to 15 characters long, and the definition can be up to
  351.       about 360 (250) characters long.
  352.  
  353.     * Function Keys
  354.     eg.     alias f1 "ed df0:s/startup-sequence^M"
  355.       This example assigns the unshifted F1 key to the text enclosed in
  356.       quotes. Note that the ^M characters puts an auto carriage return
  357.       in the definition.
  358.     eg.     alias F10 "cd df0:^M"
  359.       This sets shifted F10 to 'cd df0:<CR>'.
  360.  
  361.      Other egs.     alias f2 "cd df1:^M"
  362.                     alias f4 "genim2 "
  363.                     alias F9 "scribble df0:text/"
  364.                     alias f1 "a68k z.a;blink z.o to z^M"
  365.  
  366.     * The secondary use of ALIAS is to assign command aliases.
  367.     eg.     alias mv rename
  368.       This allows an alternate name for rename. i.e. mv.
  369.       So you could type
  370.             mv oldname newname      {to rename oldname to newname}
  371.  
  372.     eg.     alias as a68k
  373.             alias pp powerpacker
  374.             alias go "a68k zsh.s;blink zsh.o to zsh"
  375.             alias cped "copy df0:c/ed"
  376.       You would use this last alias, if you need to copy a particular
  377.       file a lot. So, to copy c/ed to ram: use:-
  378.             cped ram:
  379.  
  380.     * You can also pass external parameters to an alias.
  381.     eg.     alias al  "%1 a68k $1.s;blink $1.o to $1"
  382.     Typing
  383.                     al test
  384.     will assemble test.s using a68k, then blink test.o to become test.
  385.  
  386.     You can specify upto eight parameters to pass to a command alias.
  387.     At the start of the alias definition, specify the parameters to pass
  388.     with the variables %0 thru %7. These need not be in sequence. The
  389.     first %n will be assigned to the first parameter, the 2nd %n to
  390.     the 2nd parameter etc.
  391.     Insert the corresponding variables $0 thru $7 at the points in the
  392.     alias definition where that parameter is to appear.
  393.     eg.     alias disp "%1 %2 %3 echo \"$3 $2 $1\""
  394.             alias cram "%0 %1 %2 %3 copy $0 $1 $2 $3 ram:"
  395.             alias go "%5 %1 %6 %2 echo \"1st-$5 2nd-$1 3rd-$6 4th-$2\""
  396.  
  397.     * Command aliases can be nested to 1 level.
  398.     eg.     alias clear "echo ^L";alias cdir "%1 clear;cd $1;dir"
  399.  
  400.     * An important point about aliases, is that you can redefine the
  401.       existing internal command names.
  402.     eg.     alias help "type help_screen"
  403.       This would make it so that pressing HELP or typing H E L P would
  404.       not generate the standard help command list, but would type the
  405.       file called  help_screen to the screen. Similarly
  406.     eg.     alias copy c:copy
  407.             alias info c:dfree
  408.             alias assign .assign
  409.  
  410.     * Typing ALIAS with no parameters at all, will generate a list of all
  411.       current alias definitions.
  412.     eg.     alias
  413.  
  414.     * See UNALIAS for how to remove alias definitions.
  415. ------------------------------------------------------------------------
  416. ASK [question]
  417.  
  418.     * ASK prompts the user with a question requiring a Yes or No
  419.       answer. If the first letter of the users response is 'Y', ASK
  420.       returns code WARN. Responding 'E' returns ERROR, 'F' returns
  421.       FAIL. Any other letter will result in return code OK.
  422.       The question can include ASCII characters as well as control
  423.       codes as per the ECHO command.
  424.  
  425.     eg.     ask "Do you want commands copied to ram? "
  426.             if warn
  427.                     copy c: ram:
  428.             endif
  429.  
  430.     Note: You can redirect the ANSWER to a file by redirecting the
  431.       OUTPUT.
  432.     eg.     ask >ENV:CallIt        {The answer is written to CallIt}
  433. ------------------------------------------------------------------------
  434. ASSIGN [logical name:] [directory]
  435.  
  436.     * ASSIGN will assign a logical device name (must end in a colon (:) )
  437.       to a disk directory.
  438.  
  439.     eg.     assign z: df1:zshell_source
  440.     Now if you do a DIR Z: you will get a directory of df1:zshell_source.
  441.     Similarly, the default device names can be reassigned.
  442.     eg.     assign libs: df1:libs
  443.  
  444.     * Typing ASSIGN with no parameters, will list the current device
  445.       assignments.
  446.     eg.     assign
  447.  
  448.     ASSIGN is compatible with the AmigaDOS Assign command.
  449. ------------------------------------------------------------------------
  450. AVAIL [-C]
  451.  
  452.     * AVAIL shows the available memory as:
  453.     1.Total chip memory free,
  454.     2.Total fast memory free,
  455.     3.Total memory free.
  456.  
  457.     * With option '-c' given, it tries to free unused memory
  458.       (remove unused libraries, devices and the help manual)
  459.  
  460.     eg.     avail
  461.             avail -c
  462. ------------------------------------------------------------------------
  463. BORDER ON|OFF [number]
  464.  
  465.     * Switches the border of the window on or off. If the border is off
  466.       there will fit some more characters in a line; this can be useful
  467.       when viewing texts with MORE.
  468.     * If you run Kickstart 1.3, you should do a 'CLS' or 'echo ^L' after
  469.       using BORDER OFF.
  470.     * If you specify a number after ON or OFF, the window is resized as
  471.       large as possible. The number means the wanted distance of the
  472.       window top to the screen top in pixels. By specifying a negative
  473.       value the window will just not hide the screens menu bar.
  474.  
  475.     eg.     border off
  476.             border on 0         {fills full screen}
  477.             border off -1       {does not hide the menu bar}
  478.             border on 10;cls    {with KS 1.3}
  479. ------------------------------------------------------------------------
  480. CD [destination]
  481.  
  482.     * Changes the current directory to 'destination'. If no parameter
  483.       is given, the current directory's name is shown. It is easier to
  484.       change the directory by simply typing its name (without CD).
  485.  
  486.     eg.     cd ram:
  487.             ram:t               {same as 'cd ram:t'}
  488. ------------------------------------------------------------------------
  489. CLS
  490.  
  491.     * CLS clears the window.
  492.       It also resets the consolehandler, so if you see lots of funny
  493.       characters on the window, try CLS.
  494.     * You can do the same by using 'echo ^[c'.
  495.     * CTRL L only clears the window (same as 'echo ^L').
  496.  
  497.     eg.     cls
  498. ------------------------------------------------------------------------
  499. COPY [-R] sourcefile1 [sourcefile2] [sourcefile3] ... destination
  500.  
  501.     * There are 6 derivatives of the copy command :
  502.  
  503.      1. copy file to file.
  504.             eg.     COPY C:LIST RAM:LS
  505.      2. copy file to a directory.
  506.             eg.     COPY C:MOUNT DF1:C
  507.      3. copy multiple files to a directory.
  508.             eg.     COPY L:PORT-HANDLER L:DISK-VALIDATOR DF1:L
  509.      4. copy files in a directory to another directory.
  510.             eg.     COPY C: DF2:C
  511.      5. copy multiple directories to a single directory.
  512.             eg.     COPY L: DEVS: C: RAM:
  513.      6. Recursively copy all files and subdirectories within the source
  514.         directory to the destination directory.
  515.             eg.     COPY -R DF0: DF1:
  516.  
  517.     Other examples:
  518.     eg.     copy fred wilma
  519.     eg.     copy c:dir df1:c
  520.     eg.     copy dir list type cd df1:c
  521.     eg.     copy -r df0:devs df1:devs
  522.     eg.     copy -r source:*.s ram:
  523.             copy df0: df1:          {only copy the files in df0: to df1:}
  524. ------------------------------------------------------------------------
  525. DATE [hh:mm:ss|dd.mm.yy|mm-dd-yy]
  526.  
  527.     * DATE without arguments shows the actual date and time (systemtime).
  528.     * You can specify one or two arguments to set date or time or both.
  529.       The time format must be in HOUR:MINUTE:SECOND . Do not forget the
  530.       colon (:) between. Give only one or two digit numbers.
  531.       There exists two formats for setting the date. First is
  532.       DAY.MONTH.YEAR . Second is MONTH-DAY-YEAR . Use only one or two
  533.       digit numbers.
  534.  
  535.     eg.     date
  536.             date 14:15:00         {quarter past two PM}
  537.             date 12.5.94          {12th of May in 1994}
  538.             date 3-30-88 8:12:45  {30th of March in 1988 in the morning}
  539. ------------------------------------------------------------------------
  540. DELETE [-R] source1 [source2] [source3] [source4]...
  541.  
  542.     * Deletes one or more files or directorys ('source1','source2',...).
  543.     * If you specify the -r option when deleting a directory, then all
  544.       subdirectories are recursively deleted also. Otherwise (if the -r
  545.       option is not given) only the files in the specified directory are
  546.       deleted.
  547.     WARNING: You can hardly get back what you have deleted !
  548.              So be careful, especially when using the -r option !
  549.        (Try DISKSALV for getting lost files back, DO NOT USE DISCDOCTOR!)
  550.  
  551.     eg.     delete fred wilma barney betty dino
  552.             delete df0:devs df1:c df1:data ram:
  553.             delete menu
  554.             delete -r devs:
  555.             delete -r df1:  {better use 'format drive df1: name x quick'}
  556. ------------------------------------------------------------------------
  557. DIR [-Q] [source]
  558.  
  559.     * Lists the directory of the 'source' to the screen. Hitting space
  560.       will pause the listing and backspace will continue it. Files are
  561.       shown with their size in bytes. DIR lists the current directory
  562.       if no parameter is given. If 'source' is a filename, then only
  563.       that file is listed. If the option '-q' is not given, the filenames
  564.       will be sorted alphabetically.
  565.     * All files/dirs with the H-bit (see PROTECT) set, will not be shown.
  566.       All files that are ignored by FILENAMECOMPLETION are also hidden.
  567.  
  568.     eg.   dir df0:
  569.           dir -q devs:printers/hp*
  570. ------------------------------------------------------------------------
  571. ECHO [string]
  572.  
  573.     * Prints the 'string' to the screen. If you want spaces in the
  574.       string, make sure the whole string is enclosed in quotes. If you
  575.       want to print special control characters (eg. ctrl-L clear screen)
  576.       then prefix the control letter with a ^ character. If you want to
  577.       print double quotes, then use the \ character before the qoutes.
  578.       If you want to print some special characters like the CSI ($9B),
  579.       you can put a (hexa-)decimal number after the ^ character; you can
  580.       separate it from the next character by a point (.) . Do not forget
  581.       the ^J at the end of a line.
  582.  
  583.     eg.     echo hello^J
  584.             echo "hello world"
  585.             echo "^Lthe screen was just cleared^J"
  586.             echo "^Lline 1^Jline 2^Jline 3^J"
  587.             echo "these are double quotes ->\"^J"
  588.             echo ^$9b.33mColor^$9b.32mful^J
  589.             echo ^$9b.4mUnderlined^$9b.0mNormal^J
  590.  
  591.     * Some common control codes are:
  592.       ^7    ^G      bell (makes a DisplayBeep)
  593.       ^10   ^J      linefeed.
  594.       ^12   ^L      clear screen.
  595.       ^13   ^M      carriage return.
  596.       ^24   ^X      clear line.
  597.       ^27   ^[      escape.
  598.       ^$9b          CSI (command sequence introducer).
  599. ------------------------------------------------------------------------
  600. ELSE
  601.  
  602.     * ELSE marks the middle of an IF statement. All statements
  603.       following it, and before the ENDIF statement will be executed
  604.       only if the IF condition is FALSE. See IF for usage.
  605.  
  606. ------------------------------------------------------------------------
  607. ENDCLI [-C]
  608.  
  609.     * Exits you from ZShell back to the AmigaDOS CLI prompt or Workbench.
  610.     * If the option '-c' was specified, it will clear ZShell as a
  611.       resident: only in low memory situations needed.
  612.     * Instead of using ENDCLI you can simply press the ESC key or click
  613.       on the close gadget, if available.
  614.  
  615.     eg.   endcli
  616.           endcli -c
  617. ------------------------------------------------------------------------
  618. ENDIF
  619.  
  620.     * ENDIF marks the end of an IF statement. See IF for usage.
  621.  
  622. ------------------------------------------------------------------------
  623. EVAL expression
  624.  
  625.     * EVAL evaluates the 'expression' as a reverse polish expression,
  626.       and displays the answer in decimal and hex notation. Reverse
  627.       Polish Notation (RPN) is used in Forth and in Hewlett Packard
  628.       calculators (the best calculators in the world). It is based on
  629.       how arithmetic is actually done at the lowest possible level.
  630.       RPN allows calculating complex expressions without using brackets.
  631.  
  632.     eg.     eval 4 5 +
  633.       This gives the answer 9. When a number is found, it is 'pushed'
  634.       onto the arithmetic stack. The + always adds the last two numbers
  635.       on the stack.
  636.  
  637.     eg.     eval 7 2 3 + -
  638.       This gives the answer 2. It is the same as (7 - (2 + 3)). See,
  639.       7 is first pushed onto the stack, followed by 2, then 3. The +
  640.       adds together the 2 and 3 and leaves the result 5 on the stack.
  641.       Which means that the number 7 followed by 5 are left on the
  642.       stack. The - subtracts the last entry (5) on the stack from the
  643.       one before it (7), leaving the result 2.
  644.  
  645.     eg.     12 * (3 + 9)                    > eval 12 3 9 + *
  646.             (15 - 4) * (6 + 18)             > eval 15 4 - 6 18 + *
  647.             (6 * ((87 + 13) / (2 * 25)))    > eval 6 87 13 + 2 25 * / *
  648.  
  649.     * EVAL only performs 32 bit integer arithmetic.
  650.       Negative numbers are prefixed with - .(hexadecimal they are
  651.       shown as a 31 bit integer with bit 32 set, as usual)
  652.       Prefixing positive numbers with + is optional.
  653.  
  654.     eg.     eval +5 -3 +    {results in 2  hex:$00000002}
  655.             eval -5 3 +     {results in -2 hex:$fffffffe}
  656.  
  657.     * EVAL supports decimal, hexadecimal and binary  numbers.
  658.       If you prefix the number with $, the number is hex
  659.       If you prefix the number with %, it is binary.
  660.     Programmers: For BPTR-APTR conversion you can use & to specify
  661.       a hexadecimal APTR when asked for a BPTR and vice versa with §.
  662.     eg.     eval $c00000 $a0 16 * +
  663.  
  664.     * EVAL can also be used to perform base conversions (to dec or hex)
  665.     eg.     eval $ca
  666.             eval %10110001
  667.             eval 45
  668.             eval &5a8
  669.  
  670.     * The operators + - * / & | @ ! are supported.
  671.       The & allows logical AND'ing. And | allows logical OR'ing.
  672.       The @ is similar to PEEK in BASIC.
  673.       Conversely, ! is similar to POKE in BASIC
  674.     eg.     eval $80 $21 $08 | | $aa &
  675.             eval $67 %11001011 &
  676.  
  677.             eval $c00000 @
  678.       This prints out the long word in memory locations $c00000 -
  679.       $c00003.
  680.  
  681.             eval $aa55aa55aa $40000 !
  682.       This pokes the long word $aa55aa55aa into locations $40000
  683.       thru $40003.
  684.  
  685.     * For environment handling you can specify the value of an
  686.       environment variable with | followed by the name.
  687.       To store the result in a variable, redirect the output.
  688.  
  689.     eg.     eval >ENV:aa |ENV:bb 1 +
  690.       This adds 1 to the value in ENV:bb and stores the result in ENV:aa
  691.     * If the result was 0 an error (fail-level 10) will be returned.
  692.       If it was negative, a warn (5) returns.
  693.       (Not when redirecting output)
  694. ------------------------------------------------------------------------
  695. EXECUTE source
  696.  
  697.     * Executes the ZShell script file of name 'source'. All ZShell
  698.       commands, as well as commands from disk are valid within a
  699.       script file.
  700.     * If the S-protection-bit (see PROTECT) of 'source' is set, you do
  701.       not need to type EXECUTE, just use 'source' like a command.
  702.     * You can break scripts by pressing CTRL-D.
  703.  
  704.     eg.   execute install_hard_disk
  705. ------------------------------------------------------------------------
  706. FAILAT [failat_level]
  707.  
  708.     * FAILAT sets the error code level at which scripts (and multiple
  709.       commands on one line) will be aborted. The default level is 10.
  710.       Most commands return 10 as an error, (20 for serious errors)
  711.       while compilers returning Warning type errors will return 5.
  712.       Hence, the default of 10 will allow Warnings to occur without
  713.       the script (or line) being aborted. If a command returned an error
  714.       code higher than the failat level, it will be printed out on the
  715.       window.
  716.  
  717.     eg.     failat 20       {sets failat level to 20}
  718.  
  719.     * If you do not specify a failat level, the current setting is
  720.       shown.
  721.  
  722.     eg.     failat
  723. ------------------------------------------------------------------------
  724. FAULT [error_number]
  725.  
  726.     * FAULT displays a textual error message of the given DOS-error-number
  727.  
  728.     eg.     fault 103
  729.       {says something like 'no free store', go and buy some
  730.        extra memory :) }
  731. ------------------------------------------------------------------------
  732. FILENOTE file|directory comment
  733.  
  734.     * FILENOTE creates or changes a comment of the file or directory.
  735.       This comment can be up to 116 characters long and can be displayed
  736.       using the LIST command. It is useful if the filename does not say
  737.       what for this file is. Add a comment to this file and you will
  738.       forever know what this file does.
  739.  
  740.     eg.     filenote devs:mountlist "This is used by the mount command"
  741. ------------------------------------------------------------------------
  742. HELP [topic]
  743.  
  744.     * HELP shows the lines of this manual corresponding to the topic.
  745.       To see all topics available, type 'HELP CONTENTS' . Make sure that
  746.       this manual is in your command search path (see PATH).
  747.       For some help about a command you can also type 'commandname ?' .
  748.       Type only '?' to read the manual with MORE (see MORE).
  749.     Note: Instead of typing the topic you can only type some starting
  750.           characters.
  751.     Note: The manual is only loaded once and will stay in memory till
  752.           you use 'AVAIL -C' or 'ENDCLI -C'
  753.  
  754.     eg.    help contents       {'help cont' will do the same}
  755.            help copy
  756.            makedir ?
  757.            ?
  758.  
  759.     * HELP without a topic lists the names of all available ZShell
  760.       commands to the screen. This does not need the manual.
  761.       HELP can also be invoked by hitting the HELP key.
  762.  
  763.     eg.   help
  764. ------------------------------------------------------------------------
  765. HTYPE source
  766.  
  767.     * HTYPE outputs a hex listing of the file specified. Output is the
  768.       same as the M command. SPACE pauses the listing, BACKSPACE
  769.       gets it going again, and CTRL-C will abort the listing.
  770.  
  771.     eg.     htype c:list
  772. ------------------------------------------------------------------------
  773. IF [NOT][WARN][ERROR][FAIL][EXISTS file]
  774.  
  775.     * The IF command allows conditional execution of statements
  776.       following it.
  777.     * If the condition specified is true, then execution continues
  778.       after the IF statement until either an ENDIF or ELSE statement
  779.       is encountered. If it is an ELSE statement, then all statements
  780.       between the ELSE and the closing ENDIF are skipped.
  781.     * If the condition is false, then all statements after the IF and
  782.       before either an ENDIF or ELSE statement are skipped. If an ELSE
  783.       is encountered, then execution continues for all statements after
  784.       the ELSE and before the closing ENDIF.
  785.     * IF can examine the state of the return code from the last command
  786.       execute with WARN, ERROR, and FAIL tests. You can test for the
  787.       non existence of such a state by including the optional NOT
  788.       parameter.
  789.  
  790.     eg.     IF WARN
  791.                     echo "last command returned warnings"
  792.             ELSE
  793.                     echo "last command did not return warnings"
  794.             ENDIF
  795.  
  796.             IF NOT FAIL
  797.                     echo "last command did not fail"
  798.             ENDIF
  799.  
  800.     * IF can also test for the existence of a file or directory.
  801.  
  802.     eg.     IF EXISTS :system/format
  803.                     echo "this disk has a format command"
  804.                     echo "you can look yourself. I'm not joking"
  805.             ENDIF
  806.  
  807.             IF NOT EXISTS ram:ed
  808.                     copy c:ed ram:
  809.             ENDIF
  810. ------------------------------------------------------------------------
  811. INFO
  812.  
  813.     * Lists lots of information about all available volumes (like disks).
  814.       These columns mean:
  815.       NAME: Name of the device containing the volume
  816.       UNIT: Unitnumber, not very interesting
  817.       SYS:  Filesystem, can be one of:
  818.             OFS : Oldfilesystem (old fashioned and slow)
  819.             FFS : Fastfilesystem (needs at least Kick 2.0)
  820.             INO/INF : International OFS/FFS
  821.             DCO/DCF : Directory Cache OFS/FFS (needs Kick 3.0)
  822.             MSD : CrossDOS Filesystem (MessyDOS)
  823.             ??? : Unknown
  824.       SIZE: Maximum useable size of the Volume in KBytes (1024 Bytes)
  825.       FREE: Free/useable size in KBytes
  826.       FULL: Ratio between used size and maximum size
  827.       BLOCK: Size of a single block in Bytes
  828.       STATUS: Says if it is possible to write to that volume
  829.       ERR:  Number of soft errors, I only saw 0 yet
  830.       VOLUME: Name of the volume (name of the disk).
  831.     * Note: It would not make sense to show the free size in Bytes,
  832.       because space can only be allocated in whole blocks and one
  833.       block is at least 488 Bytes large.
  834.  
  835.     eg.    info
  836. ------------------------------------------------------------------------
  837. JOIN [sourcefile1] [sourcefile2] ... destfile
  838.  
  839.     * JOIN concatenates one or more files to form a new file (destfile).
  840.  
  841.     eg.     join fred.doc roy.doc dog.doc mydocs.doc
  842. ------------------------------------------------------------------------
  843. LAB label
  844.  
  845.     * LAB specifies a destination (label) for the SKIP command. See SKIP.
  846.  
  847. ------------------------------------------------------------------------
  848. LIST [-R] [-Q] [source]
  849.  
  850.     * Lists the directory of the 'source' to the screen. Hitting space
  851.       will pause the listing and backspace will continue it.
  852.     * LIST acts similar to DIR (see DIR), but outputs more information:
  853.      - Hidden files will be shown
  854.      - Shows the date and time of the last change (date-of-last-change)
  855.      - Shows the protection-bits (see PROTECT)
  856.      - If available, the comment will be shown (see FILENOTE)
  857.     * LIST supports recursive listing. That means the contents of all
  858.       subdirectories are shown. To use it, specify the -r option.
  859.  
  860.     eg.     list
  861.             list sys:system
  862.             list -q df0:
  863.             list -r -q *.info    {show all INFO-files in the current and
  864.                                  in the sub-directories}
  865.             list -r ram:~*.info  {show all except *.info files in RAM:}
  866. ------------------------------------------------------------------------
  867. LOCK device ON|OFF
  868.  
  869.     * 'LOCK device ON' locks the write-access to a device
  870.     eg.     lock df0: on
  871.       will make it impossible to write to or change something on the
  872.       disk inserted in DF0:
  873.     * 'LOCK device OFF' makes write-access to a device possible again.
  874.  
  875.     eg.     lock dh0: on
  876.             lock dh0: off
  877. ------------------------------------------------------------------------
  878. MAKEDIR [directory1] [directory2] ...
  879.  
  880.     * Creates one or more directories of the names specified.
  881.  
  882.     eg.     makedir temp
  883.             makedir c l s libs devs fonts
  884.             makedir devs/printers ram:c
  885. ------------------------------------------------------------------------
  886. MEMCLK ON|OFF|ALARM
  887.  
  888.     * MEMCLK is for using a clock shown in the border of the actual
  889.       window. The current total free and chip free memory are also
  890.       shown. It can do a DisplayBeep (short flash on all screens) at a
  891.       specified time. The DisplayBeep can be converted into a sound
  892.       by using a PD-utility for that or using Workbench 3.0 .
  893.     * Programmers: There will be only one 'MemClock'-Task, even if you
  894.       run MEMCLK on many windows  -> memory and CPU saving.
  895.     * MEMCLK ON switches the clock on or does nothing if it already
  896.       exist.
  897.     * MEMCLK OFF switches the clock off or does nothing if it does not
  898.       exist.
  899.     * MEMCLK ALARM shows the alarm time. If you type a time (see DATE)
  900.       after ALARM, you set the alarm time. (You cannot set an alarm date
  901.       or multiple times.) ( MEMCLK A is the same as MEMCLK ALARM )
  902.  
  903.     eg.     memclk on
  904.             memclk off
  905.             memclk alarm
  906.             memclk a 21:34:07
  907.  
  908.     * The clock can also be used on non-ZShell windows, but MAKE SURE
  909.       that the clock is switched OFF BEFORE the window is CLOSED,
  910.       otherwise you will see THE GURU (or an ALERT with KS2.0+)
  911.       For example, to get a clock on the Workbench, type in ZShell
  912.             wait 5;memclk on
  913.       and press RETURN. Now you have 5 seconds to click on the Workbench
  914.       screen. For removing use 'wait 5;memclk off' .
  915. ------------------------------------------------------------------------
  916. MORE source [line count]
  917.  
  918.     * MORE acts as a simple (ANSI) text file viewer. By default, it will
  919.       show 19 lines of a text file, then wait for some user input.
  920.       To move around in the text, you can use the CURSOR-KEYS:
  921.         UP        : Go one line up
  922.         DOWN      : Go one line down
  923.         LEFT      : Go one page (default 19 lines) up
  924.         RIGHT     : Go one page down
  925.         SHIFT-UP  : Go to the top of the text
  926.         SHIFT-DOWN: Go to the bottom of the text
  927.  
  928.       The key 'P' creates a printout of the text (sends the text to PRT:)
  929.  
  930.       The key 'S' will prompt you what to search for. If you just press
  931.       RETURN, then the last item will be searched for. Searching begins
  932.       at the second top line shown. If the item is found, the line, it
  933.       is in, is displayed as the first line.
  934.  
  935.       Typing any other key will abort you back to the shell.
  936.  
  937.     eg.     more readme
  938.  
  939.     * Specifying the optional line count will allow you to show more or
  940.       less than the default 19 lines. {Very useful for large borderless
  941.       PAL screens or small windows}
  942.  
  943.     eg.     more contents 12
  944.             more super.doc 25
  945. ------------------------------------------------------------------------
  946. NEWCLI [new_window [start_script]]
  947.  
  948.     * NEWCLI without arguments starts a new ZShell process.
  949.       Things like paths and history buffer (!) will be copied to the
  950.       new ZShell. The input/output window is created with the default
  951.       specification. The startup script will be S:ZStart.
  952.     * 'NEWCLI new_window' is used for opening a window with different
  953.       specifications than the default. If new_window is a point (.)
  954.       there will be no window and output will be send to NIL: , if there
  955.       is an input necessary, the ZShell process will just end (for
  956.       example at a end of the script S:ZStart).
  957.     * 'NEWCLI new_window start_script' is used if the name of the
  958.       startup script should be different from S:ZStart.
  959.  
  960.     eg.     newcli
  961.             newcli con:30/30/400/50/Shell
  962.             newcli con:0/18/640/182/ZShell/CLOSE/NOSIZE/NOBORDER
  963.         {this one only with KS2.0+, maximum of 80 chars per line}
  964.             newcli con:50/20/500/100/Hello s:shell-startup
  965.             newcli . ram:doassigns
  966. ------------------------------------------------------------------------
  967. PATH [-C] [path1] [path2] [path3] [path4] ...
  968.  
  969.     * PATH defines the command search path used by ZShell when searching
  970.       for disk based commands (see EXECUTING COMMANDS) .
  971.       If you give the '-c' option, the old search path will be cleared
  972.       and the new search path consist only of the given paths.
  973.  
  974.     eg.     path -c c: ram:c df0: df1:
  975.       This example will make it so that if you type a command which is
  976.       not internal in ZShell, the resident list will be searched for it,
  977.       then the current directory, then the c: directory, then the ram:c
  978.       directory, then df0:, and finally df1:
  979.  
  980.     * By omitting the -c option, you can add a number of paths onto the
  981.       existing command search path.
  982.  
  983.     eg.     path df2:c
  984.       Adds the directory df2:c onto the existing command search path.
  985.  
  986.     eg.     path df1:bin df1:myprogs
  987.       Adds the two directories df1:bin and df1:myprogs onto the existing
  988.       command search path.
  989.  
  990.     * If, however, you type path with no parameters, the current search
  991.       path will be displayed.
  992.  
  993.     PATH is not yet compatible to the AmigaDOS Path command.
  994. ------------------------------------------------------------------------
  995. PROMPT [string]
  996.  
  997.     * If no parameter is typed, the current prompt setting will be
  998.       shown.
  999.  
  1000.     eg.     prompt
  1001.  
  1002.     * If a prompt string is specified, the current prompt setting
  1003.       will be changed to that string. The character '%' specifies a
  1004.       special prompt option.
  1005.  
  1006.             %p      Insert current directory name.
  1007.             %n      Insert CLI number.
  1008.             %l      Insert current input line number (for fun!)
  1009.  
  1010.     eg.   prompt "%p> "     {default prompt. Show current directory + '>'}
  1011.           prompt "Hello ."  {shows 'Hello .' at the start of every line}
  1012.           prompt "%n.%p> "  {show CLI number, then current dir, then '>'}
  1013. ------------------------------------------------------------------------
  1014. PROTECT [filename] [h|s|p|a|r|w|e|d]
  1015.  
  1016.     * Allows you to alter/see the protection bits associated with a file
  1017.       or a directory (default: current directory).
  1018.  
  1019.     * PROTECT filename
  1020.       Shows the protection bits for the file specified.
  1021.  
  1022.     eg.   protect editor
  1023.  
  1024.     * PROTECT filename [h|s|p|a|r|w|e|d]
  1025.       Toggles the specified protection bits on the file.
  1026.  
  1027.     eg.   protect editor pd
  1028.       If 'editor' was already pure, then the pure bit would be reset.
  1029.       If 'editor' was not pure, then the pure bit would be set.
  1030.       If 'editor' was deletable, then the delete bit would be reset.
  1031.       If 'editor' was not deletable, then the delete bit would be set.
  1032.  
  1033.     eg.   protect game hprwd
  1034.     eg.   protect monitor hsparwed
  1035.  
  1036.     Bits:   'h'     hidden  V1.3
  1037.             's'     script  V1.3
  1038.             'p'     pure    V1.3
  1039.             'a'     archive V1.3
  1040.             'r'     readable
  1041.             'w'     writable
  1042.             'e'     executable
  1043.             'd'     deletable       <- V1.2 only understands this bit
  1044. ------------------------------------------------------------------------
  1045. QUIT [error_code]
  1046.  
  1047.     * QUIT forces a script file to end, and return to the shell.
  1048.       An optional error code can be passed back (ie. 5=WARN 10=ERROR
  1049.       15=BAD 20=FAIL etc).
  1050.  
  1051.     eg.     quit 5
  1052.             quit
  1053. ------------------------------------------------------------------------
  1054. RELABEL drive newname
  1055.  
  1056.     * RELABEL renames the disk specified with the newname given.
  1057.  
  1058.     eg.     relabel Empty: MY_DISK
  1059.             relabel df0: FISHMONGER
  1060. ------------------------------------------------------------------------
  1061. RENAME source destination
  1062.  
  1063.     * Renames the file or directory of name 'source' to that of
  1064.       'destination'. You can use this to move files on a disk.
  1065.  
  1066.     eg.     rename df0:c/list df0:ls        {moves and renames}
  1067.             rename ed Editor                {just renames}
  1068. ------------------------------------------------------------------------
  1069. RESIDENT [command1] [command2] ...
  1070.  
  1071.     * RESIDENT allows you load commands into memory, such that they
  1072.       will execute immediately, rather than be loaded from disk all the
  1073.       time. The benefit of RESIDENT over saving commands on the RAM:
  1074.       disk is that only one copy of the command is in memory all the
  1075.       time. RAM: based commands will use up twice as much memory when
  1076.       the command is being executed.
  1077.  
  1078.     * The limitation of RESIDENT is that only certain commands will
  1079.       work. Generally, all commands which have their PURE bit (see
  1080.       PROTECT command) set can be made RESIDENTABLE. However, RESIDENT
  1081.       does not check whether the PURE bit is set before loading, and
  1082.       hence you can try out commands to see if they work. They'll
  1083.       always work the first time. Its only when executing the 2nd
  1084.       time that the Amiga will likely crash.
  1085.     NB: Crunched programs will most likely not work.
  1086.  
  1087.     * Typing RESIDENT with no parameters will show the current list
  1088.       of resident commands:
  1089.       ADRESS is for programmers
  1090.       USECOUNT says how many times it is used right now
  1091.                ROM internal residents have negative values
  1092.       NAME means the name  (hard to guess :)
  1093.  
  1094.     * Typing one or more command names after RESIDENT will make those
  1095.       commands resident. ZShell will search the command search path
  1096.       to try and find them.
  1097.  
  1098.     eg.     resident c/list c/cd c/date c/avail
  1099.             resident ed
  1100.  
  1101.     RESIDENT is compatible with the AmigaDOS Resident command.
  1102. ------------------------------------------------------------------------
  1103. REVIEW [bytesize]
  1104.  
  1105.     With the reviewbuffer you can see that again what scrolled out of the
  1106.     window or was redirected. In the reviewbuffer are all outputs stored.
  1107.     To see what is in the reviewbuffer just press SHIFT TAB. This activates
  1108.     the MORE text reader. See MORE how to use it.
  1109.     * 'REVIEW bytesize' (re)creates a reviewbuffer with the given size.
  1110.       Can also be used to clear the buffer.
  1111.     * 'REVIEW 0' removes the reviewbuffer.
  1112.     * 'REVIEW' without arguments shows the adress and size of the current
  1113.       reviewbuffer.
  1114.     * 'REVIEW S filename' saves the reviewbuffer to that file.
  1115.  
  1116.     eg.     review 10000        {starts normal reviewbuffer}
  1117.             review 50000        {starts big reviewbuffer}
  1118.             review 0            {deletes reviewbuffer}
  1119.  
  1120.     NOTE: Because it uses a circular buffer with fixed size, this is much
  1121.      faster than having a fixed number of lines. The decrease in scrolling
  1122.      speed is neglible.
  1123.     NOTE 2: The Write function of the dos.library will be patched, so
  1124.      there might be problems with other programms that patch this too.
  1125. ------------------------------------------------------------------------
  1126. RUN command
  1127.  
  1128.     You can use this alias to make this:
  1129.             alias run "%1 echo >T:X $1^J;newcli . T:X"
  1130.     This can be used to run programs, which do not need a window.
  1131.     If you substitute the point (.) with a window-description (like
  1132.     CON:10/10/400/100/Hallo ), you can run all commands with that.
  1133. ------------------------------------------------------------------------
  1134. SEARCH file search_string
  1135.  
  1136.     * SEARCH searches for the search_string in the file. The file can
  1137.       be a binary (eg. executable) or a text. Each occurance
  1138.       will be printed on the window with highlighted search_string.
  1139.       If the file is a text, the whole line will be printed.
  1140.       If it is a binary file, it will be printed from the occurance
  1141.       to the next NULL or LF.
  1142.     * Searching is case independent (of course!).
  1143.     * To search for a string at the beginning of a line (textfile only)
  1144.       put a point (.) before the search_string.
  1145.  
  1146.     eg.     search zshell.doc "binary (eg."
  1147.             search s:startup-sequence .assign
  1148.                 {show all assigns, but not 'resident assign'}
  1149.             search c:mount $ver:    {show version number and date,
  1150.                               should work with all newer executables}
  1151. ------------------------------------------------------------------------
  1152. SETCLOCK LOAD|SAVE
  1153.  
  1154.     * SETCLOCK only works if you have a battery backed up clock (BBUC).
  1155.       It accesses the adresses $DC0000 and I do not know if it works
  1156.       with very old or very new (A1200) clocks.
  1157.     * SETCLOCK LOAD sets the systemtime (you can see the systemtime with
  1158.       DATE or MEMCLK) to the time in the BBUC (hopefully this is the
  1159.       right time).
  1160.     * SETCLOCK SAVE first resets the BBUC, then stores the systemtime
  1161.       to the BBUC.
  1162.       To set the BBUC to the right time, use DATE to set the correct
  1163.       date and time, then use SETCLOCK SAVE.
  1164.  
  1165.     eg.     setclock load
  1166.             setclock save
  1167. ------------------------------------------------------------------------
  1168. SETDATE file|directory [date/time]
  1169.  
  1170.     * SETDATE changes the date-of-last-change (DOLC) of a file or
  1171.       directory. The DOLC can be shown by simply listing this file with
  1172.       LIST (see LIST).
  1173.     * SETDATE with no date/time given sets the DOLC to the systemtime
  1174.       (see DATE,SETCLOCK).
  1175.     * If you want to set the DOLC to a special date you have to specify
  1176.       the date or time or both in a format described at 'DATE'.
  1177.  
  1178.     eg.     setdate ram:newthings
  1179.             setdate devs:mountlist 21.8.71      {very old}
  1180.             setdate murks 18:09:00 12-24-94     {future}
  1181. ------------------------------------------------------------------------
  1182. SKIP label
  1183.  
  1184.     * SKIP searches for the label within the current script file. If it
  1185.       finds it, execution continues from that point onwards. Labels
  1186.       are specified using the LAB command.
  1187.  
  1188.     eg.     lab myloop
  1189.             dir ram:
  1190.             ask "list ram again? "
  1191.             if warn
  1192.                     skip myloop
  1193.             endif
  1194. ------------------------------------------------------------------------
  1195. STACK [size]
  1196.  
  1197.     * Allows you to view or alter the current stack size.
  1198.  
  1199.     eg.     stack            {shows the current stack size}
  1200.             stack 30000      {sets current stack = 30000 bytes}
  1201. ------------------------------------------------------------------------
  1202. TYPE source
  1203.  
  1204.     * Prints to the screen the ASCII/ANSI text file specified as 'source'.
  1205.       Hitting any key will pause the listing. Backspace will restart it.
  1206.       CTRL-C will abort the listing.
  1207.  
  1208.     eg.     type readme
  1209. ------------------------------------------------------------------------
  1210. UNALIAS [alias1] [alias2] [alias3] [alias4] ...
  1211.  
  1212.     * UNALIAS removes one or more alias definitions from the alias list.
  1213.  
  1214.     eg.     alias f1 "cd df0:;dir^M"
  1215.             alias f2 "cd df1:;dir^M"
  1216.             ...
  1217.  
  1218.             alias f10 "ed df1:s/startup-sequence^M"
  1219.             ...
  1220.  
  1221.             unalias f1 f2 f3 f4 f5 f6 f7 f8 f9
  1222.             ...
  1223.  
  1224.             unalias f10
  1225. ------------------------------------------------------------------------
  1226. WAIT timeout
  1227.  
  1228.     * WAIT halts processing for the time given. Timeout is in seconds.
  1229.       You can abort this with CTRL-C.
  1230.  
  1231.     eg.     echo "I'll wait a minute"
  1232.             wait 60
  1233. ------------------------------------------------------------------------
  1234. Comments
  1235. ; blah blah blah blah
  1236. * etc etc etc
  1237. # hello ma
  1238.  
  1239.     * Placing a semi-colon, an asterisk or a hash character as the 1st
  1240.       character in the line of a script file allows you to place comments
  1241.       in it.
  1242.  
  1243.     eg.   ; This is a comment line
  1244.  
  1245.     * If you want to place a comment at the end of a line, you have to
  1246.       put ;# before it.
  1247.  
  1248.     eg.   info;#to see something interesting
  1249. ------------------------------------------------------------------------
  1250. BUILTIN COMMANDS FOR PROGRAMMERS AND ADVANCED USERS :
  1251. =====================================================
  1252. These commands are thought for users with a deeper knowledge of the
  1253. system. Maybe they are also useful for those not knowing of the system
  1254. internals (like beginners). Just try the examples to find that out.
  1255. ------------------------------------------------------------------------
  1256. BREAK task_description [signalmask|C|D|E|F]
  1257.  
  1258.     * BREAK sets some signals at a given task
  1259.     * task_description can be one of:
  1260.       - task/process name (case dependent !)
  1261.       - task/process adress
  1262.       - CLI-process number (one from 1 to 20)
  1263.       - zero (0) for this task
  1264.       It will be checked if the node-type field contains TASK or PROCESS
  1265.     * signalmask is a longword; all bits, which should be signalled,
  1266.       must be 1 . Alternatively you can specify c,d,e or f to set
  1267.       the according signal to CTRL-C,-D,-E or -F. (CTRL-C is bit 12)
  1268.     * BREAK without signalmask (and c,d,e,f) given sets all signals the
  1269.       task is waiting for.
  1270.  
  1271.     eg.     break RexxMaster    {and it will be gone...}
  1272.             break Exchange c    {Exchange will get itself off too}
  1273.  
  1274.     eg. If 2 ZShells are running. The one with the CLI-number 1 (get that
  1275.         out with prompt %n) lists a very large directory. You can break
  1276.         that by using the other ZShell typing:
  1277.             break 1 c
  1278.         Thats the same like you pressed CTRL-C on the ZShell number 1.
  1279. ------------------------------------------------------------------------
  1280. CHECK ON|OFF
  1281.  
  1282.     * Activates or deactivates the programmers status line.
  1283.  
  1284.     eg.     check on        {activates status line}
  1285.             check off       {deactivates status line}
  1286.  
  1287.       The status line (if activated) will only appear once a disk based
  1288.     or resident program has been executed. The line appears as follows:
  1289.  
  1290.     Result2: 0  time = 00:00:23.66  changes-> chip: 0  fast: 0  total: 0
  1291.  
  1292.     Result2 shows the error code that can be asked for with IoErr.
  1293.     Time shows how long the program took to execute in hours,
  1294.     minutes, seconds, hundredths (This time does NOT include the time
  1295.     it takes to load the program from disk). Changes show if the program
  1296.     has left any memory still allocated. i.e. if 200 bytes of chip
  1297.     memory were left allocated by the program, then you see 'chip: -200'.
  1298.     The Return code (the program returns in D0) is shown as Fail-Level.
  1299. ------------------------------------------------------------------------
  1300. CTRL [max_16_chars | -C [ignore_name] | -R 8_colour_digits]
  1301.  
  1302.     This command is for changing the default settings.
  1303.     * CTRL is for command-line-editing-keys-definitions (great word :).
  1304.       In other words: You can change the meaning of keys pressed with
  1305.       CTRL (Control) and some other keys (TAB ^I, Backspace ^H,
  1306.       Return ^M, Shift-Return ^J, ESC ^[).
  1307.     * 'CTRL' without arguments shows the current definitions.
  1308.     eg.     ctrl
  1309.  
  1310.     * 'CTRL WQSEIX[RYHJMLAVn' (case dependent) sets the default settings.
  1311.       To change something, just change the character corresponding to
  1312.       the key pressed with CTRL. See some lines above for some CTRL-
  1313.       equivalents ( eg. TAB is same as CTRL-I ).
  1314.       You may get confused if you define one key twice.
  1315.     eg.     ctrl QWKU         {half line deleting like KS2.0 shell}
  1316.             ctrl QWSEAXTIYMJH {...and you will have lots of fun}
  1317.  
  1318.     * There is a special meaning with the 16th character. This is by
  1319.       default the point (.), which is displayed as a 'n' (don't get
  1320.       confused). The point has a special meaning in some commands
  1321.       (ECHO,SEARCH,PUTMSG,dir back,force disk, abbreviation)
  1322.       and can be redefined using 'CTRL WQSEIX[RYHJMLAVn', but replace the
  1323.       point by the character desired. The ASCII code must be between
  1324.       32 and 64.
  1325.     eg.     ctrl WQSEIX[RYHJMLAV#  {# is now a special character}
  1326.  
  1327.     * 'CTRL -C' shows the ignored filenames when filenamecompleting.
  1328.       By default this is unset. (-C means here -Complete)
  1329.     * 'CTRL -C filedescription' defines which names are not completed.
  1330.       'filedescription' contains wildcard(s) in most cases.
  1331.     eg.     ctrl -c         {display ignore_name}
  1332.             ctrl -c *.info  {ignore *.info-files}
  1333.             ctrl -c *.info|*.bak {ignore files ending in .info and .bak}
  1334.             ctrl -c ~*.tex|*.dvi {complete only *.tex and *.dvi-files}
  1335.             ctrl -c ""      {unset ignore_name}
  1336.  
  1337.     * 'CTRL -R colours' defines the use of colours. 'colours' has to be a
  1338.       8 digit number. The digit at position x defines to what colour number
  1339.       the default colour x is mapped to. Everything clear ? (I think no!)
  1340.     eg.     ctrl -r 01234567   {sets the default colours}
  1341.             ctrl -r 01111111   {switches to one colour mode, very useful with
  1342.                                 OS3.0+ to speed up scrolling}
  1343.             ctrl -r 01233321   {if you want to use only 4 colours}
  1344. ------------------------------------------------------------------------
  1345. DISKCHANGE device
  1346.  
  1347.     * Needed for devices which do not detect a diskchange.
  1348.  
  1349.     eg.     mount rad:;diskchange rad:
  1350.        Makes your rad:-disk appear on the Workbench.
  1351.             diskchange ram:
  1352.        If the ram-disk does not exist yet, the handler will be started
  1353.        (and the ram-disk can appear on Workbench when done before LOADWB)
  1354. ------------------------------------------------------------------------
  1355. DIE device
  1356.  
  1357.     * DIE lets the handler of a device end itself.
  1358.       It seems not to work with most handlers.
  1359. ------------------------------------------------------------------------
  1360. GETMSG [portname]
  1361.  
  1362.     * GETMSG waits for a message arriving at the process-internal
  1363.       messageport (pr_MsgPort). The message will be shown, strings
  1364.       will be tried to detected (this could cause lots of enforcer hits).
  1365.       Then you will be asked if to reply the message. 'y' replies it
  1366.       and should be used normally. 'e' replies and gets back to waiting
  1367.       mode again. Abort waiting is possible with CTRL-C.
  1368.     * 'GETMSG portname' gives the process-internal port the given name.
  1369.       Then it behaves as described above.
  1370.     * See PUTMSG for examples.
  1371. ------------------------------------------------------------------------
  1372. LOCATE [-C] lock|filename
  1373.  
  1374.     * 'LOCATE lockadress' (lockadress is a BPTR) shows information about
  1375.       that lock structure. fl_Access must be -1 (write) or -2 (read).
  1376.     * 'LOCATE filename_or_dirname' gets an ACCESS_READ lock structure on
  1377.       that file/dir. (If you type -1 after the filename you should get
  1378.       an ACCESS_WRITE lock, but there seems to be an error in DOS !)
  1379.     * 'LOCATE -C lockadress' unlocks (removes) the lock structure.
  1380.  
  1381.     eg.     locate &21f45c      {shows lock on adress $21f45c}
  1382.             locate $9f5b7       {shows lock with BPTR $9f5b7}
  1383.             locate -c $9f5b7    {removes this lock}
  1384.             locate ram:rdit     {tries to read-lock ram:rdit}
  1385.             locate ram:rdit -2  {same as above}
  1386.             locate c:mount -1   {got a write-lock on c:mount ?}
  1387. ------------------------------------------------------------------------
  1388. M [start_address] [end_address]
  1389.  
  1390.     * M is a memory contents dumping command.
  1391.     * Typing M with a start and end address will display the hex and
  1392.       ASCII contents of those bytes in the memory locations specified.
  1393.     * Typing M with only a start address will display 160 bytes
  1394.       starting at the location specified.
  1395.     * Typing M with no parameters will display 160 bytes starting
  1396.       from the current memory location.
  1397.     * The current memory location is always one location higher than
  1398.       the last location shown by a prior M command.
  1399.  
  1400.     eg.   m $70000 $77fff
  1401.           m $fc0000
  1402.           m
  1403. ------------------------------------------------------------------------
  1404. PUTMSG port_description [number1|string1] [number2|string2] ...
  1405.  
  1406.     * PUTMSG is useful for testing programms which wait for a message,
  1407.       or to reactivate a task that waits for a message which will never
  1408.       arrive. PUTMSG sends a message to the given messageport.
  1409.     * port_description can be given in 5 (!) ways:
  1410.       - Name of the messageport
  1411.       - Adress of the messageport
  1412.       - 3 ways of a task_description, see BREAK. This MUST be a Process
  1413.         because the process-internal messageport will be used.
  1414.     * number|string is a longword number or a string. If it is a number,
  1415.       it will just be added to the message. If it is a string, a
  1416.       adress pointing to this string will be added to the message.
  1417.       If number1|string1 was a point (.), the message will be initialized
  1418.       as an DOS-Packet.
  1419.     * After sending the message PUTMSG will wait for the reply and show
  1420.       that reply like GETMSG. Abort waiting with CTRL-C.
  1421.     WARNING: Your machine might CRASH if you send a message to a
  1422.       (Process-internal) port that is not waiting for this message.
  1423.     NOTE: PUTMSG without arguments makes a DisplayBeep (even without a
  1424.       window) and outputs the internal register value of A5.
  1425.  
  1426.     eg.     putmsg testtask $21fd68 12
  1427.             putmsg testport "Hello World!"
  1428.  
  1429.       If you have 2 ZShells, execute in the one with CLI-number 1
  1430.       'getmsg'. Activate the other shell and type
  1431.             putmsg 1 "like some chatting ?"
  1432.       The ZShell no. 1 should display that and prompt 'reply ?'. Answer
  1433.       'y' and the message goes back again.
  1434.       Now try 'getmsg wurgutz' at one ZShell and 'putmsg wurgutz $abcd'
  1435.       on the other. Do not forget to reply.
  1436.  
  1437.     * You can use PUTMSG to use the AREXX interface of a programm. This
  1438.       works with some programms even with Kick 1.3 and no AREXX-Package.
  1439.     eg.     putmsg showdvi 0 0 0 0 0 "tofront" {gets ShowDVI to front}
  1440.       Instead of the first 0 you sometimes must write the adress of
  1441.       this task. If available replace the second 0 with a pointer to
  1442.       the rexxsyslib.library. The third 0 is called rm_Action. I do not
  1443.       know what it is for. The fourth and fifth are results, only
  1444.       interesting in the reply.
  1445.     eg.     putmsg showdvi 0 0 0 0 0 "loadnew tex.dvi"
  1446.  
  1447.     * Specify a point as first number if you want to send a DOS-Packet.
  1448.     eg.     putmsg DF0 . 0 1023 0 0 -1     {same as LOCK DF0: ON}
  1449.     If you get $FFFFFFFF as 4th longword, it was successful.
  1450.     (with Kick 1.3 you need to use FileSystem instead of DF0)
  1451. ------------------------------------------------------------------------
  1452. RECOPY [-R] [directory|file_description]
  1453.  
  1454.     * RECOPY copies a file to the same directory with a slight different
  1455.       name (new file), then deletes the old file and renames the
  1456.       new file like the old file was called. After that the new file
  1457.       is the same as the old file was (date and comment are copied too).
  1458.       You might say: What is the use of that ? - Answer: You can process
  1459.       lots of files with a LoadSeg patch or a patch at the device.
  1460.       Depending on the patch it sometimes would be a good idea to run a
  1461.       diskoptimizer after RECOPYing.
  1462.  
  1463.     * In other words: Put some powerpacked textfiles in RAM: then run the
  1464.       PowerPackerPatcher (from Nico Francois), then do 'RECOPY RAM:'.
  1465.       After that these textfiles should be unpacked.
  1466.       Similarly you can crunch whole disks (in DF0:) running a stacker-
  1467.       like programm on DF0: then doing 'RECOPY -R DF0:'. This is tested
  1468.       with EPU and might also work with XFH (from the XPK-Package).
  1469.  
  1470.     * The option -R (recursive) does the same as in LIST.
  1471.     * If no directory is specified, the current directory is taken.
  1472.     * If you want to give a file_description make sure that it contains
  1473.       at least one wildcard. For specifying a single file put a '|'
  1474.       (vertical line) behind it.
  1475.  
  1476.     eg.     recopy -r
  1477.             recopy ram:~*.info      {do not RECOPY .info-files}
  1478.             recopy ram:bigdoc|      {RECOPY only the file bigdoc}
  1479. ------------------------------------------------------------------------
  1480. RESET
  1481.  
  1482.     * Performs a COLD reset of your Amiga. i.e. RAD will go, and you
  1483.       will get back fast memory that may have been disabled. And viruses
  1484.       should disappear.
  1485.       You will be asked before resetting.
  1486.  
  1487.     eg.     reset
  1488. ------------------------------------------------------------------------
  1489. SHOW D|I|L|M|P|R|S|T
  1490.  
  1491.     * Shows some information about important exec-lists:
  1492.       - Devices
  1493.       - Interrupts
  1494.       - Libraries
  1495.       - Memory
  1496.       - Ports (MessagePorts)
  1497.       - Resources
  1498.       - Semaphores
  1499.       - Tasks (and Processes)
  1500.       Use the first character of one of them as argument.
  1501.     * The output means:
  1502.       - Adress: hexadecimal start adress of the structure
  1503.       - Pri   : Priority, often unused
  1504.       - Ver   : Number of version  (only with D,L,R)
  1505.       - Rev   : Number of revision (only with D,L,R)
  1506.       - Name  : Name
  1507.       - State : Task state (only with T)
  1508.       - SignWait : Signals, a waiting task waits for (only with T)
  1509.       - PT    : Pr means Process, Ta means Task, Tm means Task with
  1510.                 Messageport like Process     (only with T)
  1511.     * If displaying the tasklist, the CLI-number (-> CLI ?:) and the
  1512.       loaded command will be shown at processes with cli-structure.
  1513.  
  1514.     eg.     show d          {have a look at the device-list}
  1515.             show Devices    {same as above}
  1516.             show t          {This is REAL MULTITASKING ! :) }
  1517. ------------------------------------------------------------------------
  1518. STRINGS sourcefile [count]
  1519.  
  1520.     * STRINGS displays all valid ASCII strings in a file which have a
  1521.       length greater than or equal to the count. If no count is given,
  1522.       a default of 10 characters is used.
  1523.     * This command is very useful for finding out which libraries a
  1524.       program uses.
  1525.  
  1526.     eg.     strings c:zshell 20
  1527.             strings c:mount
  1528. ------------------------------------------------------------------------
  1529. TASKPRI priority [task_description]
  1530.  
  1531.     * TASKPRI sets the priority of a task, it can be displayed using
  1532.       'SHOW T'. The priority must be between -127 and 128 and should
  1533.       be within -50 and 20 to avoid system-hangups. Standard is 0 .
  1534.     * task_description is same as described at BREAK.
  1535.     * With one argument TASKPRI sets the priority of this task.
  1536.     * If task_description is given, TASKPRI sets the priority of the
  1537.       given task.
  1538.     NOTE: I did not like to call this command CHANGETASKPRI, because
  1539.           this name is really too long.
  1540.  
  1541.     eg.     taskpri 2       {This task will be preferred}
  1542.             taskpri -1 3    {affects CLI no. 3}
  1543.             taskpri 4 Workbench
  1544. ------------------------------------------------------------------------
  1545. VEC
  1546.  
  1547.     * Displays some important execbase pointers, which give a good
  1548.       indication of whether a virus is present in your system.
  1549.       WarmCapture, CoolCapture, ColdCapture, KickTagPtr, KickMemPtr,
  1550.       and KickCheckSum are displayed. If any of these are are NOT
  1551.       zero, then either a virus, RAD, or virus protector or some
  1552.       other program that takes control of your machine when you
  1553.       reset, is present. If you suspect a virus, you may want to eject
  1554.       the disk from DF0: and type the RESET command, which should
  1555.       clear the virus. Now you should boot up on a clean disk.
  1556.  
  1557.     eg.     vec
  1558. ------------------------------------------------------------------------
  1559. ========================================================================
  1560. ------------------------------------------------------------------------
  1561. TIPS & HINTS
  1562.  
  1563.     Use MORE instead of TYPE.
  1564.     Useful aliases:
  1565.             alias arexx "%1 %2 putmsg $1 0 0 0 0 0 \"$2\""
  1566.         So 'arexx showdvi "tofront"' is the same as the example in PUTMSG.
  1567.             alias run "%1 echo >T:X $1^J;newcli . T:X"
  1568.         This can be used to run programs, which do not need a window.
  1569.         If you substitute the point (.) with a window-description (like
  1570.         CON:10/10/400/100/Hallo ), you can run all commands with that.
  1571.         If you want some shortcuts like MessyDOS:
  1572.             alias md makedir
  1573.             alias ren rename
  1574.             alias del delete
  1575.             alias dc diskchange
  1576.         These are only needed for Kickstart 1.3:
  1577.             alias setenv "%1 %2 echo >ENV:$1 $2"
  1578.             alias getenv "%1 type ENV:$1"
  1579.             alias unsetenv "%1 delete ENV:$1"
  1580.  
  1581.     A script counting down from 10 to 0 (a bit complicated and slow) :
  1582.             failat 11 ; setenv helpenv 11
  1583.             lab backtohere
  1584.             copy >NIL: ENV:helpenv ENV:counter
  1585.             eval >ENV:helpenv |ENV:counter 1 -
  1586.             echo "Current number: " ; eval |ENV:helpenv
  1587.             if not error
  1588.             skip backtohere
  1589.             endif
  1590.  
  1591.     From Workbench assigns are most likely done by clicking an icon:
  1592.         For example if you have the assigns below in the script
  1593.             failat 10
  1594.             assign TEX: dh0:text/pastex
  1595.             assign MF: dh0:text/pastex/metafont
  1596.             putmsg
  1597.         you need to get a PROJECT ICON for that. Now define the default
  1598.         tool as ZSH (or ZShell) and a tooltype containing
  1599.             WINDOW=.
  1600.         (case sensitive). That's all. Failat 10 breaks the script if
  1601.         an error occurs. Putmsg flashes the screen to indicate that
  1602.         everything was successful. No window will be opened.
  1603. ------------------------------------------------------------------------
  1604. POSSIBILITIES FOR FUTURE IMPROVEMENTS
  1605.  
  1606.     * Make the PATH command AmigaDOS compatible (near future !).
  1607.     * Make use of more KICKSTART 2.0+ features like ASSIGN ADD.
  1608.     * Improve script file execution, like passing arguments,
  1609.       allow subroutine scripts and commands like FOR.
  1610.     * More flexible environment variable handling.
  1611.     * AmigaGuide (tm) compatible documentation.
  1612.     * Include MOUNT/MOVE/INSTALL command.
  1613.     * Rewrite COPY/DELETE.
  1614.     * Scrollbar for review-buffer
  1615.     * Faster scrolling (jump scroll/1 bitplane scroll)
  1616.  
  1617. If you want to see these or other improvements made, please write to me.
  1618. ------------------------------------------------------------------------
  1619. CHANGES
  1620.  
  1621. UP TO V1.3:See the source code of the ZShell V1.3 release
  1622.            (for example on FISH disk 537).
  1623.            Author: Paul Hayter
  1624.            Source: 103 KByte, Executable: 13 KByte, Doc 32 KByte.
  1625. V2.0:There were so many changes, I think there is no sense in listing
  1626.      them all here, because it may be longer than this document. So just
  1627.      read this document or the source code.
  1628.      All changes since V1.3 made by Martin Gierich. Released 14.10.94.
  1629.      Source: 180 KByte, Executable: 25 KByte, Doc 72 KByte.
  1630. V2.1:* IMPORTANT FOR THOSE WHO USED ZSHELL V2.0: Do not start ZShell V2.1 *
  1631.      * if ZShell V2.0 is resident. This will crash your machine !         *
  1632.      * Do not use ZSH V2.0 with ZShell V2.1 and vice versa.               *
  1633.    - Added a review buffer to see that again what scrolled out of the
  1634.      window (see REVIEW). A scrollbar will probably added in future.
  1635.    - Added possibility to specify window when starting from CLI.
  1636.    - Changed default CTRL-keys; added 2 new CTRL-keys (see HISTORY &...).
  1637.    - Changed usage of MORE (you can still use the cursor keys).
  1638.    - DIR now hides all these files that Filenamecompletion ignores.
  1639.    - Some bugs found with mungwall and scratch are fixed.
  1640.    All changes since V1.3 made by Martin Gierich. Released 11.12.94.
  1641. ------------------------------------------------------------------------
  1642. COPYRIGHT FOR THE V1.3 PART
  1643.  
  1644. ZSHELL IS FREELY DISTRIBUTABLE. YOU CAN DISTRIBUTE THIS AS LONG AS
  1645. THIS DOC FILE REMAINS WITH THE EXECUTABLE, AND THAT NO CHARGE IS MADE FOR
  1646. THEM (APART FROM A NOMINAL COPYING CHARGE). IF YOU FEEL LIKE SENDING
  1647. ME SOMETHING FOR THIS PROGRAM, SEND ME A POSTCARD!, A P.D. DISK, A
  1648. PROGRAM YOU'VE BEEN WORKING ON ,BUT DON'T SEND ME ANY MONEY (WELL, IF
  1649. YOU REALLY, REALLY WANT TO, I GUESS I COULD PUT UP WITH IT).
  1650. ------------------------------------------------------------------------
  1651. COPYRIGHT FOR THE V2.0/2.1 PART
  1652.  
  1653. This may be confusing, that there are two copyrights, but I (Martin) did
  1654. not like to change the original copyright notice. The parts belonging
  1655. to V2.0 are marked in the source code with 'V2.0'.
  1656. ZSHELL IS FREELY DISTRIBUTABLE. YOU CAN DISTRIBUTE THIS AS LONG AS
  1657. THE TWO EXECUTABLES REMAIN WITH THIS DOCUMENTATION TOGETHER (AND PLEASE
  1658. DISTRIBUTE THE SOURCE FILES WITH THEM TOO), AND THAT NO CHARGE IS MADE
  1659. FOR THEM (APART FROM A NOMINAL COPYING CHARGE).
  1660. IT IS NOT ALLOWED TO USE ZSHELL COMMERCIALLY !
  1661. I would like to get your comment on ZShell to see if anybody is using it
  1662. and what can be improved. See 'CORRESPONDENCE' for my adress.
  1663.  
  1664. Amiga, AmigaDOS, Workbench and Kickstart are registered trademarks of
  1665. Commodore-Amiga Inc.
  1666. ------------------------------------------------------------------------
  1667. DISCLAIMER
  1668.  
  1669. USE THE FILES OF THIS PACKAGE ON YOUR OWN RISK !
  1670. The authors are in no way responsible for what you are doing with it
  1671. or what it does to you or your soft- and hardware.
  1672. ------------------------------------------------------------------------
  1673. CREDITS FROM PAUL
  1674.  
  1675.     Many thanks to Wayne for his invaluable help in doing the history
  1676.     and command line editing parts of ZShell. Also, thanks to
  1677.     Tim Strachan who asked for the history stuff.
  1678.     ZShell was entirely written using Wayned by Wayne Hayter (various
  1679.     versions). And was assembled with A68K V2.61 by Charlie Gibbs. And
  1680.     linked with Blink V6.7 by the Software Distillery.
  1681.  
  1682. CREDITS FROM MARTIN
  1683.  
  1684.     Many thanks to the tree people who wrote me: Laura, Igor and Willem;
  1685.     especially to Laura for some beta-testing.
  1686.     Thanks to Frank for using ZShell.
  1687.     I hope that in future some more people write to me.
  1688. ------------------------------------------------------------------------
  1689. CORRESPONDENCE & BUG REPORTS
  1690.  
  1691.   * Please send any correspondence and/or bug reports referring V1.3
  1692.     to me at the address below:-
  1693.  
  1694.             Paul Hayter
  1695.             PO Box 331
  1696.             Ballina
  1697.             2478
  1698.             AUSTRALIA
  1699.  
  1700.   * Please send correspondence, bug reports, comments, suggestions
  1701.     for future improvements etc. referring V2.0/2.1 to this adress:
  1702.  
  1703.             Martin Gierich
  1704.             Narzissenweg 7
  1705.             76297 Stutensee
  1706.             GERMANY
  1707.  
  1708.     If you have EMAIL access, please send me one at this adress:
  1709.  
  1710.             uj3w@ibm3090.rz.uni-karlsruhe.de
  1711.     or to   uj3w@rz.uni-karlsruhe.de
  1712.  
  1713.     There might sometimes be some problems with the email system,
  1714.     so if I got the mail I will reply it.
  1715. ------------------------------------------------------------------------
  1716.