home *** CD-ROM | disk | FTP | other *** search
/ Micro R&D 1 / MicroRD-CD-ROM-Vol1-1994.iso / os20 / cli / man16.lha / Man.doc < prev    next >
Encoding:
Text File  |  1993-12-16  |  5.3 KB  |  217 lines

  1.  
  2.  MAN, written by Kai Iske July 27. 1993
  3.       This is PUBLIC DOMAIN; you may do with it whatever you like
  4.  
  5.  
  6. If you change/republish/delete/sell the program or do anything similar, please
  7. be so kind to keep my name within the program and all the other files.
  8.  
  9. MAN  was  written  because  of  the fact that MRMan (by Mark Rinfret) had some
  10. severe  problems  under  OS 2.x (or was it 3.x).  Anyway, I wrote this tool in
  11. order not to have to keep in mind the locations of all the various man pages I
  12. spread across the subdirectories of my MAN:  directory.
  13.  
  14. MAN was written using SAS 6.3 / 6.50....
  15.  
  16. !!! Man requires OS 2.x and up to run !!!
  17.  
  18.  
  19. -----------------
  20. What does MAN ???
  21. -----------------
  22.  
  23.  
  24. Well, it is a MAN command similar to the one found on any UNIX System.  Simply
  25. type  "man dummy" and the manual pages (documentation) for a file called dummy
  26. will  be searched for.  If man was successful in finding the appropriate file,
  27. a textviewer will be used to display the documentation.
  28.  
  29. You may configure MAN in order to tell the program where to find the man pages
  30. and  what  text  viewers  to  use.   Wait a minute.  Textviewers ???  Yep, MAN
  31. recognizes the following suffixes as to be part of man pages:
  32.  
  33.   .doc   - Simple ASCII text file
  34.   .man   - Simple ASCII text file
  35.   .guide - Got it, AmigaGuide compatible guide file.
  36.  
  37. So now you know why there are different textviewers.
  38.  
  39.    For example...
  40.  
  41.       You have the documentation for a program called "KCommodity" somewhere
  42.       within your docs directory. The doc file is called "KCommodity.Man". In
  43.       order to get the documentation loaded by man, simply type:
  44.  
  45.           MAN KCommodity
  46.  
  47.       ...and the ASCII textviewer will be used. If your filename ends up with
  48.       .guide ("KCommodity.guide"), MAN assumes it to be a GUIDE file and will
  49.       use the GUIDE Viewer instead...
  50.  
  51.       See, no suffixes needed. MAN will take the first file matching a
  52.       suffix mentioned above.
  53.  
  54.  
  55. You may even add features to MAN using environment variables. Read on...
  56.  
  57.  
  58. ----------------------
  59. How to install MAN ???
  60. ----------------------
  61.  
  62. Copy the main program to a directory within your search paths (i.e. C:).
  63.  
  64. Simply set three environment variables, so that MAN knows what to do:
  65.  
  66.  
  67.  
  68.    MANPATHS  - This variable tells man where to look for man pages.
  69.  
  70.    For example...
  71.  
  72.       SetEnv MANPATHS "MAN:,MAN:CSHDOC|MAN:HPDOCS,MAN:AUTODOCS"
  73.  
  74.    You see, you may either use "," or the "|" as seperators between
  75.    directory names.
  76.  
  77.  
  78.  
  79.  
  80.    MANVIEW   - This one is the path (including filename) for the
  81.                textviewer you wish to use for displaying normal
  82.                ASCII files.
  83.  
  84.    For example...
  85.  
  86.       SetEnv MANVIEW "SYS:Utilities/More"
  87.  
  88.    REMEMBER: Complete path and filename
  89.  
  90.  
  91.  
  92.  
  93.    MANVIEWAG - This one is used to set the path (and filename) for
  94.                the AmigaGuide GUIDE-Viewer.
  95.  
  96.    For example...
  97.  
  98.       SetEnv MANVIEWAG "SYS:Utilities/AmigaGuide"
  99.  
  100.    REMEMBER : Complete path and filename
  101.  
  102.  
  103.  
  104. Additionally there are three more environment variables you may use to add
  105. extensions and functions to man. These are :
  106.  
  107.    MANNRMEXT - You may use this variable to add extensions to the already
  108.                known, which should be treated (shown) as plain ASCII files.
  109.  
  110.    For example...
  111.    
  112.       SetEnv MANNRMEXT ".txt|.asc|.dok"
  113.  
  114.    Will add these extensions to known ASCII files
  115.  
  116.  
  117.  
  118.  
  119.    MANAGEXT  - Using this variable you may add extensions for AmigaGuide
  120.                files
  121.  
  122.    For example
  123.  
  124.       SetEnv MANAGEXT ".bla|.blo|.blu"
  125.  
  126.    Will add these extensions to known AmigaGuide compatible files
  127.  
  128.  
  129.  
  130.  
  131.    MANNOVIEW - If a file doesn`t end up with an extension (starting with a
  132.                dot), MAN will use the perdefined ASCII viewer to display
  133.                such a file. You may change the viewer for suche files using
  134.                this variable. Additionally this option may be turned off,
  135.                when you issue a zeor length string "".
  136.  
  137.    For example
  138.  
  139.       SetEnv MANNOVIEW "SYS:Utilities/AmigaGuide"
  140.  
  141.    Will tell MAN to display files, without extension, using AmigaGuide
  142.  
  143.  
  144.  
  145.  
  146. It is best to place those lines within your S:User-StartUp file.
  147.  
  148.  
  149.  
  150. -----------
  151. Version 1.0
  152. -----------
  153.   - initial release
  154.  
  155.  
  156. -----------
  157. Version 1.1
  158. -----------
  159.   - Accidentially called Exit() instead of exit(), which
  160.     prevented the program to pass the cleanup code of SAS.
  161.     So a lock to the directory was kept and the shell could
  162.     never been left.............
  163.  
  164.  
  165. -----------
  166. Version 1.2
  167. -----------
  168.   - Used MAN as a keyword for the template which prevented MAN
  169.     to accept inputs like "man man".
  170.  
  171.  
  172. -----------
  173. Version 1.3
  174. -----------
  175.   - Added CTRL-C checking
  176.   - Recompiled using SAS 6.50
  177.   - Reduced stack usage
  178.   - Reduced executable size
  179.  
  180.  
  181. -----------
  182. Version 1.4
  183. -----------
  184.   - DOS-Library wasn`t closed
  185.  
  186.  
  187. -----------
  188. Version 1.5
  189. -----------
  190.   - Referenced free memory area
  191.  
  192.  
  193. -----------
  194. Version 1.6
  195. -----------
  196.   - Added MANRMEXT, MANAGEXT and MANNOVIEW options,
  197.     which may be used for extensibility of MAN
  198.     (Somehow suggested by : Michael 'Mick' Hohmann)
  199.  
  200.  
  201. Hope you like it, if not, delete it......
  202.  
  203.  
  204.  
  205. So long,
  206.  
  207.      Kai
  208.  
  209.  
  210.  
  211.  
  212.  --- Kai Iske
  213.  Brucknerstrasse 18, 63452 Hanau, Germany, Tel.: +49-(0)6181-850181
  214.  Z-Net    : KAI@SWEET.ZER            usenet : kai@iske.adsp.sub.org
  215.  internet : iske@informatik.uni-frankfurt.de              IRC:kiske
  216.  ---- Life sucks ----
  217.