home *** CD-ROM | disk | FTP | other *** search
/ Otherware / Otherware_1_SB_Development.iso / amiga / utility / misc / dc23.lha / dc / dc.man < prev    next >
Encoding:
Text File  |  1992-06-13  |  5.3 KB  |  147 lines

  1. NAME
  2.     DC - Direct Change V2.3
  3.  
  4.  
  5. SYNOPSIS
  6.     DC <patterns> [-b] [-q] [-e] [-i] [-r]
  7.     DC <devs/...> -u [-q]
  8.  
  9.  
  10. DESCRIPTION
  11.     DC changes the current directory like CD does, but requires only a
  12.     tiny piece of the directory path as a parameter. DC looks for a match
  13.     in a database of the directory paths in your system, and changes
  14.     the current dir directly to that path. Thus, navigating your shell
  15.     through large directory trees becomes fast and convenient.
  16.  
  17.     For instance, typing "CD WORK:Program/Source/MyTools" reduces to
  18.     "DC w:sou/my" or even a "DC myt" assuming the pattern "myt" doesn't
  19.     occur elsewhere. If it does, you can cycle through these multiple
  20.     matches until you've found the directory you are looking for. This
  21.     is done simply by rerunning DC using the same pattern.
  22.  
  23.  
  24. INSTALLATION
  25.     DC requires WorkBench 2.0 or higher. The database containing the
  26.     directory paths can be updated by typing "DC <list of volumes> -u".
  27.     The directory trees of all specified volumes will be stored in
  28.     file "Devs:.dc". This location is currently hardwired but will be
  29.     made configurable in future updates. Updating the database should
  30.     be done regulary so as to have it reflect recent changes in your
  31.     directory trees. If you use a Cron scheduler, I suggest you add
  32.     the update entry to your CronTab.
  33.  
  34.     Once the database has been created you're ready to go, in principle,
  35.     but every time you invoke DC it will load the .dc file from disk.
  36.     To greatly speed up operations you may wish to install the .dc file
  37.     in RAM as a semaphore by adding "DC -i" to your startup sequence.
  38.     DC is pure and can be made resident for added performance.
  39.  
  40.     Before I forget, as an added bonus, you may compress the devs:.dc
  41.     file using FImp. FImp is a compression utility from the Imploder 4.0
  42.     distribution.
  43.  
  44.  
  45. MATCHING ALGORITHM
  46.     Operation is as follows. The first thing that happens when you use
  47.     DC with a directory name or part of a directory name is a normal
  48.     CD operation. DC tries to lock the directory and if it succeeds
  49.     changes the current directory accordingly. If it fails, DC examines
  50.     the current directory name and if it matches the supplied pattern
  51.     it will change to the next directory matching this pattern.
  52.     So multiple invocations of "DC s" will cycle you through all
  53.     (sub)directories containing a character "s". When the supplied
  54.     pattern is not matching with the current directory DC tries to
  55.     'guess' what the best match will be and jumps to this directory.
  56.     DC is not case-sensitive.
  57.  
  58.  
  59. OPTIONS
  60.     <patterns>    :consists of a partial directory name, no wildcards
  61.              supported (yet).
  62.     -b        :used in conjunction with <pattern> to
  63.              jump to the best matching directory.
  64.     <devs/...>    :consists of a list of devices and/or volumes separated
  65.              by space or comma.
  66.     -u        :used in conjunction with <devs/...> to update the
  67.              directory cache file. May take a while...
  68.     -i        :installs directory cache in public memory.
  69.     -r        :removes directory cache from memory.
  70.     -q        :quiet flag, to disable some default messages.
  71.     -e        :echo's result to the standard output instead of
  72.              changing the current directory. Used in conjunction
  73.              with pipes and command line substitution.
  74.  
  75. EXAMPLES
  76.  
  77.     DC WB_2.0: WORK: -u    :creates directory file DEVS:.dc for
  78.                  volumes WB_2.0: and WORK:
  79.  
  80.     DC -i -q        :places directory cache resident in memory
  81.  
  82.     DC system        :will take you to _a_ ...:.../.../#?system#?
  83.                  directory, if one exists e.g. WB_2.0:System
  84.  
  85.     DC vs/pr        :takes you to _a_ ...:.../#?vs#?/.../#?pr#?
  86.                  directory, upto 16 partial pattern separated
  87.                  by a / or : are allowed
  88.  
  89.     DC -r            :removes directory cache from memory
  90.  
  91.     Your (daily) update scheme, worst case, may look like this:
  92.     DC WB_2.0: WORK: "RAM DISK:" -u  : update path database
  93.     Sort DEVS:.dc TO DEVS:.dc        : depends on personal preferences
  94.     FImp DEVS:.dc DEVS:.dc           : to save a few bytes
  95.  
  96.  
  97. WSHELL 2.0
  98.     WShell 2.0 users have complained that the prompt or shell titlebar
  99.     current directory strings won't be updated after a directory change
  100.     using DC (or any other external program for that matter). To amend
  101.     this, the following work-around has been contrived; in Config-WShell
  102.     add the lines
  103.         alias DC     LITERAL cd "`DCR -e []`"
  104.         resi C:DC as DCR
  105.     This has the added benefit that AUTO PUSHCD will still work with DC
  106.     as well as adding wildcarding normal CDs using DC.
  107.  
  108.  
  109. BUGS
  110.     Directory cache format is not very efficient. On the other hand,
  111.     it's readable and editable.
  112.  
  113.     Links are not supported. Due to problems with cycling through
  114.     all directories containing the specified pattern. During update
  115.     any encountered hard- or softlink will be intentionally left out!
  116.  
  117.  
  118. FUTURE IMPROVEMENTS
  119.     Only(?) 16 volumes can be specified on the command line,
  120.     but this can easily be overcome by concatenating different
  121.     .dc files.
  122.  
  123.     Support for some kind of directory-exclusion.
  124.  
  125.     When the xpk compression standard is released DC will probably
  126.     support a XPK'd directory file. (wow!)
  127.  
  128.     Unhardwire database location.
  129.  
  130.  
  131. LEGAL STUFF
  132.     DC is FreeWare. Period. If you like DC and you've some suggestions,
  133.     comments, bugreports, or whatever please send 'em to me by e-mail.
  134.  
  135.  
  136. HISTORY
  137.     ...    lots of beta test versions, lost history.
  138.     2.0    1.3 hacks removed, Workbench2.0 only now
  139.     2.1    added multiple subpattern support
  140.     2.2    fixed (another) directory priority bug
  141.     2.3    cleaned up for first public release...
  142.  
  143.  
  144. AUTHOR
  145.     Peter Struijk
  146.     winfjmf@dutiws.tudelft.nl (mention my name)
  147.