
                               NewList 7.1a
                        (too good to be GNUlist!)
                                   by

                               Phil Dietz
                               PO Box 306
                             Yutan, Nebraska
                                 68073

                               25-Dec-92



===========
Disclaimer:
===========

      This is TuitionWare.  Send some bucks to help me get through college.
    It's only a few bucks.  It's a heck of a lot cheaper than a lot
    of Shareware out there and you get _infinite_ updates!

======================
My Gripes about Demos:
======================

      This is NOT CrippleWare.....this is NOT Pay-to-get-the-better-version-
    ware...this is NOT a demo...Newlist7.1 is the real thing!
    CrippleWare falls into a class I call CommercialWare.  Sure ComercialWare
    improves donations, but what a waste!  When I take my time to download
    a file, I don't want it wasted with a crippled version!  I toss them
    when I see them...no matter.  Newlist7.1 is not a demo so enjoy :-)

==============
Register info:
==============

      It's completely optional.

      If you register however you will get:
          - infinite updates of newlist for FREE
          - updates mailed to you (even to foreign lands!)
          - a FREE disk with each newlist update filled with other
             new exciting PD programs I like!!
          - a neat (and official :-)  'I support shareware' certificate
             to show off to your friends saying you care for Amiga Shareware
          - discounts on any commercial ventures I may take (soon!)

      The registration fee is whatever you want!  If you can't convert to
      dollars, then just send some ECUs.  If you can't send 20 bucks then
      send 1 buck.  If you can't send money, send a gift for my new
      apartment (a lamp, a book, an a4000 etc. :-)

             If you like newlist a lot then support newlist.

==========
Spread It:
==========
       Entire newlist71 package should never change.

       Please upload newlist71 to your favorite BBS.
       Please upload newlist71 to your commercial network (portal, etc.)
       Please offer  newlist71 to your user group.
       Please tell your mother-in-law to use newlist71 :-)

       Commercial PD companies:
           All documentation must accompany newlist.
           You are free to distribute the newlist71 package....but
           try to send me a note about what list I made :-)

================
What is Newlist?
================

      NewList is the ultimate 'ls' utility.  Currently there are a 100
   ls-type utilities out there.  Unfortunately, they all lack something.
   If they had the power, then they lacked the speed, and vice versa.

      NewList fixes all of their inadequacies.

      Newlist has customization.  Newlist has speed.  NewList has power.
   The best of ls, the best of ddir, the best of list, and bunches
   of my own special features were all put into one small and efficient
   package.  With NewList, the user is given processing power.
   You can sort a directory the way YOU want it.

      Newlist was designed to be quick and offer all the MEAT commands
   most CLI users need.  From the ground level on up, newlist was
   optimized and new features were designed to be their quickest.
   Through proper code generation, newlist has added more powerful features
   than most list replacements, while becoming faster at the same time.

   Fast flexible file manipulation, nice powerful customization,
   and all those extra 'goodies' were melded into one.

=======================
Is it too much for you?
=======================

   If you are one of those leary about newlist's power (you think it's too
   much for you or your brain too handle :-)  take it nice and slow.  I
   guarentee after a day or 2 of using newlist and it's flags, you will start
   to realize what you can do with newlist, and you will appreciate all of
   the features I have put in.

====================
Features of NewList:
====================

   +  Localization for foreign users.
   +  WB2.0 compatible!!!
   +  Complete link support, detection, and traversal.
   +  Very fast algorithms and 'tight' code.
   +  Tons of sorts and filters (name, date, size, as-read, even comments!)
   +  Completely dynamic.
   +  Full UNIX and AmigaDOS wildcards (n*l*s#? = newlist)
   +  ANSI.
   +  Complete ENV: support with permanent and conditional variables.
   +  Date  construction kit with 8 premades (or create your own!)
   +  Print construction kit with 2 premades (or create your own!)
   +  Header construction kit.
   +  Multi-column contruction kit.
   +  3 different type of recursion.
   +  Built-in hunt mode like whereis
   +  Flexible argument passing with multiple path support.
   +  A Pager.
   +  It's PURE!  NewList is REALLY quick if it's resident.
   +  Fetches console window bounds and adjusts accordingly.
   +  3 slick multi-columnar quick options to utilize screen space.
   +  a built in StarBurst utility for * wildacrds.
   +  Tons and Tons and Tons O' Flags and Switches!
   +  Optimized and Optimized!
   +  SAS6.1 compiled!


Usage:   NewList ? or Newlist -?

NewList  7.1  INTL WB2.0 only  by  Phil Dietz  NCEMRSoft
NewList  [FLAGS ie. -rqt -p] <paths and wildcards>
       o  Overlook ENV:NEWLIST* variables    e  Append ENV:NEWLIST to flags
       p  Use Pager                          Z  No ANSI
     b k  Show blocks or disk keys           a  No 'Today' substitution
       u  Show DEVICE: usage info            h  No header
       n  Show comments                      t  No totals
gd gf gl  Show ONLY dirs, files, or links    Q  No system requesters
      gm  Mixed output dirs & files          i  Show *.info files
    s ss  Sort by name or filesize       X pat  Exclude pattern
   sc sr  Sort by comment or as-read     d0..8  Eight date/time formats
   sd sn  Sort by date or no sort            S  Stat totals only
       r  Reverse the sort                   z  C= list style directories
       R  Enter subs w/wild one level        A  Include assign add's
       W  Enter subs w/wild ALL levels       /  Add / to dirs and > to links
       H  Hunt for files on disk       q qs qt  Quick short directories
       J  Do not enter links                 v  Horizontal sort quick style
      x#  Max # dir-levels to enter         y#  Quick option uses # columns
   c pat  Comment wildcard                   =  Seperator line
       P  Use FULL path for names            K  Kill buffer
     ] [  Show/hide 'a' archived             B  Use relative path names
     L l  dd-mmm-yy or #  Files made before/after date or # days ago
       C  Custom header format " %s and all date formats "
       D  Custom date   format " %ABCmdyHNSvItT \nte' \f#b#s#o"
   E M F  Custom print   format " %pUdbksvcCNnP  \nte' \f#b#s#o"

===============
FLAGS IN DEPTH:
===============

   Note:  All these flags are compatible with newlist71 WB2.0 version.  
     Older versions may lack commands or may run different.

  ========================
   Miscellaneous Commands
  ========================

   [-?]   Usage Help.

   [-o]   When you want to OVERLOOK the ENV:NEWLIST, ENV:NEWLIST_QUICK,
           ENV:NEWLIST_LONG, and ENV:NEWLIST_BOTH variables.  Using [-o]
           will ignore your ENV: settings and use the newlist defaults.

   [-e]   Appends the conditional variable ENV:NEWLIST to your current
           flags.  Normally when you give a flag, your ENV:NEWLIST is
           skipped.  Giving [-e] will tell it not to skip your environment
           settings.
                        nl -p   skips ENV:NEWLIST     
                        nl -pe  uses  ENV:NEWLIST

   [-p]   Turns on pagnation.  When each screen fills, a prompt
           will be be put up so you can read all the files before they fly
           by!  The prompt contains the current grand totals as well as
           some neat inverse video effects.  

                        [Space] - next full page
                       [Return] - next line
                            [n] - non-stop (turns off paging)
                   [Esc] or [q] - quit newlist

          If you re-direct the output of newlist, paging will be turned off.

   [-a]   Forgets about the TODAY, YESTERDAY, bologna.

[-b] [-k] Instead of the default display of filesize, newlist will
          instead display BLOCKS or DISKKEYS respectively.

   [-u]   Shows bytes FREE and bytes USED on disk.  Now you can get
          all your needed info with one command instead of a "dir
          list info" combo.  Note: due to RAM:'s variable size,
          the bytes free will be zero.   Also note: sometimes the
          size is off....I don't know why, but be aware.

   [-n]   Do you hate seeing those huge FILENOTES destroying your
          directory list?  This flag will toggle if you want to see them.
          If not present, a simple "Comment" or "c" will be shown to tell
          you "hey mister, you can read me if you wanna."

   [-h]   Turns off the header.....ohhhhh.....big deal!
          If you are auto-executing [-E] a format, [-h] will turn off
          the verbose output.

   [-t]   Don't show totals.

   [-Z]   Forces ANSI sequences off.  Piping data in shells is different
          than redirecting so nl can't tell when to turn off ANSI
          automatically.  Thus you must give [-Z] whenever you pipe.
          (Or use handy alias 'piper')

   [-Q]   Turns off system requesters.   No more bothersome 'Please 
          insert disk' requesters.  Since requesters are off, unmounted
          things like soft links will not be traversed.

          Note: system-requesters are turned on when fetching assign-add
                directories.

   [-/]   Append a slash '/' to directories and a '>' to links.  
          Output is similar to NeXT Unix, A/UX, and dr.
          The link sign '>' will only be printed in [-q] mode.
          Oh yeah, I think the '@' is an ugly motha so I switched to the '>'

   [-=]   Prints a seperator line between the dirs and the files.

   [-S]   Stats only option.  Only prints totals for each directory.
          All newlist filters (*.c -l1 etc.) will still affect the results.

   [-A]   Include Assign Add's.  WB2.0 allows multiple assigns to a name
          (ie many font dirs point to fonts:)  This option will have newlist
          fetch all the different assign paths and view them.  Wild
          cards, recursion, and multiple ASSIGN: paths will still work 100%.

[-d0...8] Eight different pre-made date formats.

          -d0   -   Locale.library format
          -d1   -   YY.MM.DD HH:MM:SS
          -d2   -   MM/DD/YY HH:MM:SS
          -d3   -   Day Mon DD Year HH:MM:SS AM
          -d4   -   YY.MM.DD
          -d5   -   MM/DD/YY
          -d6   -   Day Mon YY
          -d7   -   Day Mon [YYY or HH:MM]
          -d8   -   Date Stamp Values

          These formats can be changed by editing your NEWLIST_LANG file.

   [-P]   Expands filename to include full path.  This allows a no-hassle
          way to see full path names without having to create a custom
          format with a %P character.  [-P] does not expand quick listings.

   [-B]   Will use relative path name instead of absolute.  So you will
          see FONTS: instead of dh0:fonts for example.  Added because
          a BBS owner wanted to hide his absolute path names from his users.

   [-K]   Frees all memory newlist71intl previously allocated (about 5k).  
          After [-K] is given, newlist71intl will have to re-parse
          the ENV:NEWLIST_LANG file.
          Use [-K] when you need the 5k newlist71intl reserves or
          use [-K] when you want to try a new locale file.

  ===============================
   Groupings, Sorts, and Filters
  ===============================

  Various filters and sorts to suit most everone.  Mix and match.

 -gd -gf  Groups the display so ONLY dirs, ONLY files, or ONLY links are
   -gl     shown respectively. Similar to 'dir dirs' or 'dir files'
           To show only dir links or file links, use -glgf or -glgd

  [-gm]   Shows BOTH directories and files in mixed order.

  [-gb]   Seperates dirs and files...it's now the default value of newlist,
             but this flag is left in for backwards compatibility.

   [-s]   Sorts files alphabetically.

  [-ss]   Sorts files by file size (or blocks [-b]).

  [-sd]   Sorts files by time (date of creation).  Very handy!!

  [-sc]   Sorts files by comments.  If you use FileNotes wisely, you can
          have your directories be grouped by file type.  Simply
          add a filenote to each file and give it a type (Picture, GIF,
          Utility, NoiseTracker, etc.)   Now when you view by [-sc],
          the files will be grouped together by type!  You can also use
          the included alias 'dirtype' which will display the filetype 
          in a nice position.

  [-sr]   Sorts files as-read (actually as hashed), but fully buffered.
          To sort by diskkey use [-sr -k].

  [-sn]   No sort.  This is the default for Commodore's list.
          This method uses the least memory and is the fastest.
          This format prints files as-read.

   [-r]   Displays a list in REVERSE from top to bottom.  WHY?   
          Instead of waiting for the whole list to scroll by to see a
          file at the bottom, you can reverse the list and ctrl-c to
          stop quick!  It's also handy when sorting by date.  All of
          the newest files will be displayed first.

   [-i]   Show *.info files!

 [-X pat] Exclude a wildcard pattern.  This will NOT show files that match
          the pattern.   ie  nl -X *.info  will hide all *.info files.
          You may chain as many as you like, but each pattern needs a [-X]
          flag.   ie  nl -X *.c -X *.o -X *.lnk  
                  or  nl -X *.(c|o|lnk)
 
 [-c pat] Comment wildcard!  A very interesting idea from Tim Boland.
          He mentioned that he has his comments on his files telling where
          he got the file (Fred Fish Disk 597 or A-LINK BBS etc.)  With
          [-c pat] command, you can say for instance

              nl -c "*Fish 597"       to get all files on FF 597
              nl -c "*Fish 59*"       to get all files in FF 590 series
              nl -c "[amicus|*Fish]*" to get all Amicus or FF files

          [-c pat] can also be used for a SHOW-ONLY commented files group
          filter.  To show only files with a comment do a nl -c ?#?
          or a nl -c ?*

   [-l]   dd-MMM-yy or # days
          Show files made in the last # days or files made since dd-MMM-yy.
          Suppose today is Sun 10-Nov-91 and you want to see files made
          yesterday.  You can enter these:

          nl -l 1     nl -l 09-Nov-91   nl -l Saturday    nl -l yesterday

          Note how you can enter the # of days, the date, the day name
          (Friday, Saturday, etc.), or today, yesterday, etc., to represent
          the same thing!

          Day names like Saturday represent 'last Saturday' not
          'this coming Saturday.'

   [-L]   dd-MMM-yy or # days
          Show files made before # days ago or files made before dd-MMM-yy.
          See above [-l] for examples of usage.


    -]    Show files with the 'a' archived bit set.  The following
            produces a list of all files on dh0: that have been archived.

                              nl -]iH dh0:

    -[    Show files without the 'a' archived bit set.  The following
            produces a list of all files on dh0: that NEED to be archived.

                              nl -[iH dh0:

                         Also see script 'BackUp'

  =============================
   Short Multi-Column Displays
  =============================

   Short displays.  Lots of different variations for the choosing.
   A sort will be used (name by default) none is given.

   [-q]   Gives a QUICK and easy listing of the directory.  The entire
          screen will be utilized and multi-columns will be created.
          Names will be white, and directories will be another color.
          Because of its simplicity, not all of the flags are usuable.
          (like -D etc.)  Vertical sort is the default.

  [-qs]   Quick option WITH file-sizes!  A very very handy option very
          similar to DIR opt s, but with multi-columns.  Note: if you'd
          rather see blocks or keys instead, add -b or -k (ie nl -qs -b)

  [-qt]   Quick Option WITH file-sizes!  Similar to ddir output with
          filename followed by size.  Long file names will be 
          TRUNCATED (up to 13 chars) to fit inside it's column.  Column
          width is variable depending on filename lengths and widowsize.
          Make the window smaller, then the columns become smaller....
          if they become to small (too much truncation) it will use
          fewer columns.  Blocks [-b] and keys [-k] also work.

   [-v]   Horizontal sort the [-q -qs -qt] outputs.  Without
          [-v], vertical sort is default.  Issuing [-v] implicitly
          means [-q -v].

 [-y #]   Force # columns for [-q] quick option.  Use this option when
          re-directing the output to a WIDE printer.  ie. to use 9
          columns for a printer with 20 pitch type, use  nl >prt: -qy9 dh0:

   [-M]   Custom Multi-Columnar ouput.   See Below.


 ===================
  Custom Formatting
 ===================

  Newlist's power comes from it's custom formatting.  While other 'ls'
  programs have formating, they LOSE THEIR SPEED.  Newlist doesn't.

  For help creating custom formats, consult

            'docs/FormatTutorial.doc' for a tutorial
            'scripts/Aliases'         for examples

  -----
  DATE:
  -----

   [-D]   Custom Date Format.  Use if your country has different format.
          The format is -D "DATE STRING".  Here are the flags available:
 
          %A -  foreign date from DateToStr (use with locale.library)
          %B -  foreign time from DateToStr (use with locale.library) 
          %C -  foreign day  from DateToStr (use with locale.library)
          NOTE: %A, %B, and %C are quicker than custom formats.  The
           results should also be in a foreign language if you
           are running a foreign OS with WB2.1 or greater.

          %y -  year  as 2 digits  (90)
          %Y -  year  as 4 digits  (1991)
          %v -  year if older than 1 year...or else the time.
             ^Note: no truncation  (.#) allowed for %v..use %5v and not %5.5v
          %m -  month as 2 digits  (07)
          %M -  month name         ("January".."December")
        %.3M -  abbreviated month  ("Jan".."Dec")
          %d -  day of month       (1-31)
          %D -  day name           ("Monday".."Sunday")
        %.3D -  abbreviated day    ("Mon".."Sun")
          %h -  hour in twenty-four hour notation
          %H -  hour in twelve hour notation
          %I -  12 hour indicator for H notation (AM or PM)
          %N -  minutes
          %S -  seconds
          %t -  prints TODAY, YESTERDAY, or Day name if applicable
          %T -  two must be present.  Mark off block which will be
                substituted with Today, Yesterday, if applicable.
                If not applicable, it will process the inner block.
                (ie  -D "Date: %T%3M %2d%T" will sometimes print
                Date: Today  or  Date: Mar 16)
\n, \t, \e, \' -  Newline, tab, escape key, or quote ".  \e can be used 
                  to make neat ANSI sequences.  See aliases 'color'.
         \b# -  sets background color (0-9)
         \f# -  sets foreground color (0-9)
         \s# -  sets style       (0-9)
         \o  -  resets ansi for normal output
         \C  -  Adds color string defined in language file under _NAMECOLOR:


	              Make a C string like printf.
               -D "Date: %02d-%3.3M-%02y at %02h:02n:02s" 

                               yields
                   Date: 09-Nov-91 at 01:03:20

                    It's Easy.  It adds spice.

   -------
   Header:
   -------

   [-C]   Custom header format if you do not like the default.
          Here are the meta-characters:

          %s - Displays Path Name
          %R - Adds relative path name (currently only assign add names)
          All date meta-characters above for -D (ie. %N, %M, etc.)

             An ie:  nl -C "\n%s on %02d-%3.3M-%02y\n"
           w/color:  nl -C "\n\f3%s\o on \f3%02d-%3.3M-%02y\o\n"

                    See 'aliases' file for neat examples.

   -------------
   Short Format:
   -------------

   [-M]   Custom Multi-columnar output.  Similar to [-q] short format,
          but all of the flags in -F and -D can be used!
          [-M] will not put a '\n' newline out until either:

               1)  you have a forced column setting
                   ie nl -y3 -M "%n"   forces 3 columns
               2)  it will print off the window.

          You WILL need to use expanding.truncating to get the output
          in nice columns.  For example: nl -M "%-20.20n %U "

          Vertical and horizontal sort will not work on this data.

   ------------
   Long Format:
   ------------

   [-F]   Custom print format.   Now you can design the
          way YOU want the output to be.  Here are the flags supported:

           %b -  block size
           %c -  'c'       if filenote available
           %C -  'Comment' if filenote available
           %d -  Date (this date can be constructed with -D!)
           %k -  disk key
           %n -  file name
                  %.5n -  file name truncated to 5 chars
           %N -  filenote
           %p -  show protection bits
           %P -  file name with complete path
           %s -  file size
           %v -  variable output.   Depends if [-b] [-k] or [none] are used.
           %U -  UNIX protection bits. Adds d for dirs and H/S for links
                  Routine distinguishes directory and file links.
           %L -  Prints expanded link names in the form
                  " -> Full-path-of-file".  Soft Links that have
                  their link not mounted will be displayed as
                  " -> !myfile".  
                  Bad links will be " -> :UNKNOWN FILE:"
            
   \n, \t, \e, \'  -  Add newline, tab, escape charater, or quote ".  These 
                 sequences may be used to create neat ANSI stuff.   Check
                 out 'color' in the file 'aliases'.  \' is very useful
                 when filenames you are manipulating contain spaces.
                 It you put \' around the name ( \'%n\' ) most DOS
                 commands will now recognize the file.
           \b# - sets background color (0-9)
           \f# - sets foreground color (0-9)
           \s# - sets style       (0-9)
           \o  - resets ansi for normal output
           \C  - Adds color string defined in language file under _NAMECOLOR:


                 Here is a UNIX ls format example
        -F " %U %c %4b  %7s %d %n" -D "%.3M %2d %02h:%02n"

      Custom print formats also allow easy batch script making!
      This format will make a script file test.script that will
              show all display all pictures in a drawer

              nl >test.script -F "display \'%n\'" *.iff

     This format will make a script file test.script that will
      copy ALL files made in the last 2 days to df1: 

         nl >test.script -l2 -HF "copy \'%P\' to df1:" *

              So ya still like LS?  Take off, ya hoser.

   -------------
   Auto Scripts:
   -------------

   [-E]   Execute print format immediately.  The format takes the form
          of [-F] above.

          This will prevent unnecessary script files from being generated.
          For example:

                        nl sounds:* -E "sound %P"
                     will play all sounds in sounds:.

                  nl -H -l1 -E "copy %P to backupdisk:" dh0:
               will copy all files made in the last day on dh0:
                           to your backupdisk:.

          If you want to copy or move files, etc. with spaces in them
          ("Read Me"), you should pad the filename with quotes so
          Amiga will run it properly.  (ie nl -E "copy \'%P\'" )
                                                       ^   ^
                                                    Quote Characters
      
          By default, -E prints in verbose mode (prints Executing xxx....)
          To turn it off, turn off the header with [-h] flag.
     
          WB2.0 version will allow interactive input and output with
          CLI programs so you can "delete %P ASK" or whatever.   WB1.3
          version DOES NOT!


  ==========================
   Recursion and Hunt modes
  ==========================
   
   Recursion is where you enter subdirectories, print info, enter
   it's subdirectories etc.  It's similar to dir opt all.  

   Newlist has 3 different types of recursion available.  Mostly they
   affect how the wildcard will be applied.  Here's how they work:

          ie   nl [-R|-H|-W] dh0:c*   will list

                           use [-R]
                         candy/snickers (dir)
     [loose wild]         cars/datsun
                          cars/cadillac
                          cars/yugo

             (ALL files in dirs ONLY starting with c)

                          use [-H]
                       candy/chocolate (dir)
      [hunt mode]       cars/cadillac
                      drinks/coffee
                      lemons/cray-computer

         (ONLY files and dirs starting with c in ALL dirs)

                          use [-W]
     [strict wild]      candy/chocolate (dir)
                         cars/cadillac

     (ONLY files starting with c in dirs ONLY starting with c)


     [-R] uses the wildcard only on the first level.  All files
          and subdirectories after that will be displayed.
     [-W] uses the wildcard on all levels.  Only files and directories
          matching the wildcard will be shown/entered.
     [-H] enters every single directory no matter the wildacard,
          and will only print info that matches the wildcard.


   [-R]   Recursion.  This will use wild card ONLY for the first level.

        nl -R FF:n*   will show complete listings of dirs that
            start with n.

        FF:nebraska (dir)    FF:names (dir)   FF:numbers (dir)
        Omaha                Phil             One
        Lincoln              Justin           Two
        etc.                 etc.             etc.

   [-W]   Will exclusively use wildcard to match files and sub-directories
          on EVERY level.  ONLY files matching wildcard will be shown
          and ONLY subdirectories matching wildcard will be entered.

          [-W] is the method that ls uses- enter only dirs matching pat

   [-H]   Hunt files down.  Will recursively enter subdirectories, but 
          will enter all directories regardless of wildcards, etc.  Why?
          Now let's say you want a list of all 'c' files on your harddisk.

                           Simply  nl -H dh0:*.c

          Besides matching wildcards, [-H] will also accept the other
          conditional flags (like -i -l etc.)

          Now you can view all files made since yesterday....

                           nl -H -l yesterday dh0:

          [-H] enters every directory it finds (up to -x #) levels and
          tries to match corresponding files and dirs.

          Hunt mode will now match both files and directories.   If you
          want to see only matching files, use [-gf] with it.

   [-J]   Jump links.  Newlist will not enter or follow links when in
          recursion mode.  Works in conjunction with -R, -W, or -H.

 [-x #]   Only enter # subdirectory levels in recursion mode.  Otherwise it 
          will enter every sub-directory it will find.
          Use with [-R, -W, -H].  Root level only is [-x 0].
 

=================
Important Points:
=================

     -------------------------------
     Paths- the directories to view:
     -------------------------------

     + You can have more than 1 path.  Just add it. ie

                  nl df0: df1: df2:

     + Paths on the command line will be entered from right to left.

     + The Amiga currentdir character "" may not always work.
       An alternative is to have a single wild card, *.
       nl * vd0:  will list vd0: then the current directory.

     -----------------------------------------
     Flags- how they work and are interpreted:
     -----------------------------------------

     + All of the flags and paths can be used in ANY order.  

                         nl dh0: -s df1: -r
       is the same as    nl dh0: df1: -s -r

     + Flags may be joined together:  nl -rsgmi  
                          seperated:  nl -r -s -gm -i
                            or both:  nl -rs -gmi

     + Flag parsing ignores whitespace.  So if you say

          nl -F"%n" 
       or nl -F[TAB][TAB]"%n" etc. they will be the same.

     + Most flags allow switching back and forth.

            nl -a   is on    
            nl -aa  is off    
            nl -aaa is on etc.

     + Precendence of flags goes as follows:
         
                          flags from
                          ----------
          Most Priority : Command Line
                          ENV:NEWLIST
                          ENV:NEWLIST_BOTH
          Least           ENV:NEWLIST_QUICK or ENV:NEWLIST_LONG

     + All of the flags can be used together (-q has exceptions):
       You can view a directory of files made in the last 2 weeks,
       sorted by date in reverse order, showing block size , with
       a custom dateformat string, custom print string, hiding 
       .info files, paging, using a UNIX wildcard, etc. etc.

     -----------------------------
     Wildcards- how they are used:
     -----------------------------

     + Both Amiga and UNIX wildcards are supported
       To use a wildcard simply add it right after the path 

               (ie dh0:*.c)

     + The wildcard MUST be connected to it's path.  If you say

                nl dh0:*.c    (right)
                nl dh0: *.c   (wrong)

       NewList will think you want a dir of dh0: AND a dir of
       files matching *.c in the current directory.

     + Each new path may have a totally different wildcard

          nl *.doc ram:*.c df0:*.lzh c:d?r df0:
             ^                ^             ^
         just wildcard       both      just path
        (assume current               (assume * as
           directory)                   wildcard)

     + "nl ?" brings up the help message.   

        To use '?' as a UNIX wildcard add a space ' ' or a flag 
        or a path before the '?'.

         "nl ?"  or  "nl -?"            get help

         "nl ? " or  "nl ? -s" 
                 or  "nl dh0:?"      use '?' as wildcard

     ----------------------------
     Supported wildcard patterns:
     ----------------------------

       ?     Matches a single character
       #     Matches the following expresion 0 or more times
    (ab|cd)  Matches any one of the items seperated by |
       ~     Negates the expressions
     [abc]   Character class: matches any of the characters 
                in the class
     [~bc]   Character class: matches any of the characters NOT 
                in the class
      a-z    Character range  ie [a-l]
       %     Matches 0 characers always  (useful in "(foo|bar|%)")
       *     A synonym to #?
 (ab*|*xy*|~*.c)  A compound wildcard

========================
Support for WB2.0 Links:
========================

      NewList has complete support for WB2.0's new link format.
      NewList has the BEST link support available.  This complete support
      includes:

        1) Hard links, soft links, and pipes are supported.

        2) Links will be shown VIA the UNIX style protection bits.

           ie   dH----rwed   and   -H----rwed
                ^(dir link)        ^(file link)

           depending if they point to a directory or a file.  Hard
           and soft links will also be shown by the bits H and S
               after the d

           ie   dH----rwed        and   -H----rwed
                ^(dir hard link)        ^(file hard link)

                dS----rwed        and   -S----rwed
                ^(dir soft link)        ^(file soft link)

                            -P----rwed
                             ^pipe

        3) Link names can be fully expanded to tell where they point too
                         link -> dh0:source/newlist

        4) Soft links will be distinguished as being dir links or file links.
           Thus, softlinks will be transparently identical to hard links.
           (softlinks do not tell if they point to a file or a dir.  NewList
            will find out for itsself.)

        5) Intelligent link traversals.  Circular directories and back-links
           will not confuse newlist (unlike Commodore 'list'!)
           A special method is used to prevent nonterminating loops.
           A directory will ONLY be shown once.  If a link wants to show
           it again, it will be ignored.

        6) Bad soft links or links that can't be resolved will be 
                       detected and have the value:
                         link -> :UNKNOWN FILE:
   
        7) [-/] flag will display links with a trailing >.  Dir links
           will be _NAMECOLOR: while file links will be color1 (use -gb to
           easily separate the two).  Links will also be Italicized.

        8) Soft links that are not mounted will have a ! in front of
           them.    ie.   link -> !df1:myfile

        9) Recursive modes [-R -W -H] by default will traverse links.
           If you wish for them not to be traversed, give [-J] jump option.

       10) Better link utilities are given in my LinkSupport package.
           A new 'makelink' utility that supports soft link generation
           and a 'deletelink' utility to erase them are included.  They
           include full 'C' source.

=============================
Environment Variable Support:
=============================

      Environment variables allow a user to define his or her own default
   settings for newlist.  There are 4 different variables one may set.
   They are ENV:NEWLIST, ENV:NEWLIST_QUICK, ENV:NEWLIST_LONG, and
   ENV:NEWLIST_BOTH.  They are not all the same.  One is conditional
   and the other 3 are semi-permanent.

              ENV:NEWLIST_QUICK   permanent variables
              ENV:NEWLIST_LONG     "           "
              ENV:NEWLIST_BOTH     "           "

              ENV:NEWLIST         conditional variable   

   ----------
   Permanent:
   ----------
      If you want a flag to always be set, use these variables.  They are:

                               ENV:NEWLIST_QUICK
                               ENV:NEWLIST_LONG
                          and  ENV:NEWLIST_BOTH.     

      These will load in all cases except when [-o] is given.  These flags
      are designed for permanent flags like custom date and print formats,
      as well as other permanent type data.  Depending on how you execute
      newlist, certain variables will be loaded:

        ENV:NEWLIST_QUICK will be read only for a quick [-q] format.
        ENV:NEWLIST_LONG  will be read only for a long format.
        ENV:NEWLIST_BOTH  will be read for either long or quick.

      Be careful with the permanent settings.  The settings are set
      every time you run newlist.   If you have a variable like short
      output [-q] in your ENV:NEWLIST_BOTH and you want a long output,
      *you will have to turn it off by hand* by toggling it back off
      (nl -q) or by forgetting ENV: all together with a [-o].

   -----------
   Conditional
   -----------
         The conditional variable ENV:NEWLIST loads only in certain
      circumstances.  They are:

            1)  No flags are given                  (ie nl df0:)
         or 2)  The [-e] append ENV: flag is given. (ie nl -pe)

      If you give ANY flag (ie nl df0: -p) or if you give the [-o] flag
      then ENV:NEWLIST will NOT be loaded.

      One uses the conditional variable ENV:NEWLIST when one wants certain
      flags to be used most of the time.  This allows you to easily change
      from one newlist output to another without many hassles.  

      For example...lets say your ENV:NEWLIST is a sort by date "-sd"
      Giving 'nl -q' will skip ENV:NEWLIST and thus sort by name (default)
 
    ----------
    Precedence
    ----------
       Custom formats and non-toggle variables on your command line and
       in your ENV:NEWLIST have precedence over those in ENV:NEWLIST_*.

       Any custom format issued on the command line or in ENV:NEWLIST
       will override your ENV:NEWLIST_* setting.  

       Flags and switches like [-p] do NOT have a precedence.
       They will always be toggled.  If ENV:NEWLIST_* has a [-p] for 
       paging on and ENV:NEWLIST has a [-p] for paging on, paging will
       be toggled off.
    
       Most Priority : Command Line 
                       ENV:NEWLIST
                       ENV:NEWLIST_BOTH
       Least           ENV:NEWLIST_QUICK or ENV:NEWLIST_LONG

   -------
   Summary
   -------
      The majority of your flags should go in permanent variables 
            NEWLIST_LONG, NEWLIST_QUICK, or NEWLIST_BOTH.

      The conditional variable NEWLIST is only for the flags you want
                           conditionally set.


      Here's a short summary of what ENV: files will be loaded.
      Lets say you have all of the ENV: variables defined...

        nl df0:        will load ENV:NEWLIST (since no flags on command line)
                       will load ENV:NEWLIST_LONG  (if long output)
                   and will load ENV:NEWLIST_BOTH

        nl -p df0:     will load ENV:NEWLIST_LONG   (since long out mode)
                   and will load ENV:NEWLIST_BOTH

        nl -q df0:     will load ENV:NEWLIST_QUICK  (since short out mode)
                   and will load ENV:NEWLIST_BOTH

   -------------------------
   Things you can do w/ ENV:
   -------------------------
      
      Examples:   Commodore style to be the default
                       setenv NEWLIST_BOTH -z
      for die->   Short output listing as default (like ls)  
      hard ls          setenv NEWLIST_BOTH -q  (or qs or qt :-)
      users       Special header for small style
                       setenv NEWLIST_QUICK "-C *"\b3Test String\o\n*""
   
===================================================
How to set ENV:NEWLIST and ENV:NEWLIST_* variables:
===================================================

     Make sure ENV: is assigned to a permanent directory.  Now use the 
   Commodore supplied command setenv.  Here is my ENV:newlist setting:

               setenv  envarc:NEWLIST  "-sd -u -Q"
    or better  setenv  envarc:NEWLIST  "-sduQ"

    ------------------------------------------------------------------
    NOTE: the shell parses quotes (").  
          To set an ENV: variable with quotes from the shell, you must
          escape them with:

              setenv  envarc:NEWLIST  "-D *"Year %4Y*" -ss"
                                          ^^      ^^
                                        escaped the quote
    ------------------------------------------------------------------

    You may also edit the flags with a text editor like ed:

                     ed  envarc:NEWLIST
                   copy  envarc:NEWLIST env:

    If you have no permanent envarc: replace all instances with env:

=============
Localization:
=============

   Localization has been added to newlist7.  Newlist7 does _NOT_ require
   WB2.1 or above, only WB2.04.  Localization allows users to rewrite the
   internal strings of newlist to run in their own native language. 
   So now Newlist can be German...Dutch...Polish...or whatever :-)
   As a benefit, you can change the ANSI colors and styles so the
   output is to YOUR personal liking!

   Use the supplied install script:

      cd Languages
      Execute Install_Lang

                                 - or-

   Simply copy your lang file as NEWLIST_LANG to ENV: or locale:


   At anytime you wish to edit the language..simply edit ENVARC:NEWLIST_LANG

      To edit language:   Simply edit the   ENVARC:NEWLIST_LANG 
                                         or locale:NEWLIST_LANG


   Newlist7intl parses the NEWLIST_LANG file *only 1 time*, after that
   further calls will use the parsed strings already in memory!!  This 
   drastically increases newlist's performance.  If at any time you want
   this 5k of memory back or if you want to change the NEWLIST_LANG file,
   you can free this memory with the [-K] option.

    To change lang file:   execute Install_lang
                              -or-
                           nl71intl -K
                           cp newlist_lang.xxxx envarc:newlist_lang
   
                           Whallah...
   
                 I hope all of you enjoy localization!!!  
                 Now newlist has COMPLETE customization.
   
   NOTE: NEWLIST_LANG is not a WB2.1 catalog. I have no WB2.1 documentation!

=======================
WB2.0 tip O' the day 1:
=======================

      Do you miss the really fast scroll displays of wb1.3?  I've found
    a way to get them back!  You can open a shell that disables the
    super-auto-refresh and console cut-and-paste to increase scrolling 
    speed by 20+%!  Do the following to open a WB1.3 style fast shell:

      newshell CON:0/0/640/200/PhilDOS/CLOSE/SMART
                                              ^
                                              this is the secret!

    To gain even more speed, use a 2 color public screen and close WB.

=======================
WB2.0 tip O' the day 2:
=======================

      Wish your shell had more than 80 columns?  Now you can use any size
   font with WB2.0's neat new command setfont.  Try this out:

      setfont topaz 7 scale    and   setfont topaz 20 scale
                        ^
                        this is the secret!

      NewList will recognize the new font and will adjust its output!
   Try the 7 point font and nl -q.  Cool huh!


========================
How to install Newlist7:
========================

      To install the newlist package simply use the install script:

                      execute Install-NewList

      or to install manually:
      1) a. copy newlist71          to c:nl
         b. copy newlist71intl      to c:nl
         c. copy newlist71intl.030  to c:nl

      2) Add  'resident c:nl pure add' to your s:user-startup script.

      3) Set ENV: variables with
           setenv ENVARC:NEWLIST       "flags" to set conditional flags.
           setenv ENVARC:NEWLIST_LONG  "flags" to set permanent long flags.
           setenv ENVARC:NEWLIST_QUICK "flags" to set permanent quick flags.
           setenv ENVARC:NEWLIST_BOTH  "flags" to set permanent flags.
       
      4) Foreign users:  execute Install_lang

      5) (Optional)
         Create any aliases you may need and append them to your
                   S:Shell-Startup from a Shell with:
  
                 type >>s:Shell-Startup Scripts/Aliases

===========
Final Note:
===========

      Enjoy.  Keep in mind: this is a super useful tool!
              It's like one of those 1001 in 1 cooking tools.

                "Flip the lever, and now it makes
                 julienne style potatoes! [clap....clap]  You get the
                 slicer, the dicer, the juicer, and turkey jerky maker
                 for only $49.95!  But wait there's more......"

              Oh my....I've lost my mind :-) 

      Register and recieve unlimited updates, your name in my docs,
        and an 'Official' shareware patron certificate to show off to
        all your friends!

      Mail comments, tips, bug reports, new features, new languages files,
         and Shareware donations to:

                  Phil Dietz -- NCEMRSoft        EMAIL: pdietz@cse.unl.edu
                  PO Box 306         
                  Yutan, Nebraska 68073  
                  USA            

