home *** CD-ROM | disk | FTP | other *** search
/ Beijing Paradise BBS Backup / PARADISE.ISO / software / BBSDOORW / NEXP20.ZIP / NUREAD.ME < prev   
Encoding:
Text File  |  1992-11-15  |  8.8 KB  |  193 lines

  1. NUEXPIRE.PL  Version 2.0    11/15/92
  2. A Waffle maintainence utility for MS-DOS Waffle BBS systems.
  3. by Roy M. Silvernail (roy%cybrspc@cs.umn.edu)
  4. This program is in the public domain.
  5. =========================================================================
  6. New for V2.0
  7.     Added '-autonuke' to unconditionally nuke the whole spool.  This can
  8.     be useful if you have to make an unexpected trip out of town.
  9.     The 'ignore group' option now works more intuitively.  A trailing
  10.     period will confine protection to only that group. (same syntax as
  11.     the /waffle/system/feeds file)
  12.     NUEXPIRE does a chdir() to each directory, to speed up the stat()
  13.     process.  Articles are considered for expiry if they are regular
  14.     files.  (formerly, no article was considered unless it an
  15.     all-numeric name)  This will break some 1.64 usage, if your articles
  16.     are above 32,767.  Sorry... upgrade to 1.65 or trim your newsgroups
  17.     on occasion.
  18.  
  19. New for V1.8
  20.     Added "-s" to just display statistics of how long each group is kept.
  21.     The static file parsing now allows lines of the form 'flag:option' (with
  22.     no whitespace).
  23.     The 'local' forum file is not processed.
  24.     (changes courtesy of Bill Fenner, to whom I tip my hat!)
  25.  
  26. New for V1.7
  27.     Default /expire flags are now respected.  Many little tweaks.
  28.     NUEXPIRE should be run with perl 4.0, for best results.
  29.     There is a little documentation on the debug flags.  Try
  30.     'nuexpire -d99' to see it, or just look at the bottom of the
  31.     NUEXPIRE file.
  32.     The logfile works properly now, instead of logging every article
  33.     considered.
  34.  
  35. New for V1.6
  36.     Now supports expiry of groups in all forum description files.
  37.  
  38. New for V1.5
  39.     Added the -nuke option, to clean all possible material from the news
  40.     spool, while still maintaining the Waffle numbering.  High messages
  41.     in each group are truncated to 0 bytes.
  42.  
  43. New for V1.4
  44.     Fixed a small bug that left 0-byte files laying around.  This was a
  45.     byproduct of the logfile option.
  46.  
  47. New for V1.3:
  48.     A group or set of groups can be spared for a given run, using the -x
  49.     switch.
  50.  
  51. New for V1.2:
  52.     A log of deleted articles can be kept.
  53.     The documentation has been improved a bit.
  54.  
  55. New for V1.1
  56.     A small bug with graded expire is fixed.
  57.  
  58. NUEXPIRE.PL is an expire utility designed for maintainence of MS-DOS
  59. Waffle BBS systems.  NUEXPIRE will expire news articles based on age,
  60. expire those articles that have been read by a certain user, or remove
  61. all the news on your news spool.  NUEXPIRE also supports a grading
  62. system and a command-line exclusion switch, whereby certain newsgroups
  63. can be selectively excluded from expiry.
  64.  
  65. NUEXPIRE reads the environment variable WAFFLE to locate the
  66. /waffle/system/static file.  From that file, it determines where the
  67. waffle files are and where the user directory tree starts.  NUEXPIRE
  68. does not process the 'local' forums description file.
  69.  
  70. NUEXPIRE uses information in the forum description files in
  71. /waffle/system for expiry.  Proper directory names are constructed from
  72. the newsgroup definition lines.  If an alternate directory is specified
  73. with /dir, NUEXPIRE uses that directory for that particular group.  If
  74. the /expire flag is set to a numeric value (/expire=5), that value will
  75. be used for timed expire of that group. The value is the age of the
  76. article in days. Otherwise, the command-line value will be used.
  77. Optionally, a graded expire value can be set.  Setting /expire=NO ,
  78. /expire=0 or /expire=NEVER will exempt a group from being expired at
  79. all.  All directory names are adjusted to 8 characters, to allow usage
  80. on a Novell network.
  81.  
  82. NUEXPIRE can reference your join file, and expire articles already read.
  83. This is most useful to a single-user site, and replaces the
  84. functionality of the older SUEXPIRE.PL.
  85.  
  86. Newsgroups can be given a grade to simplify administration.  A flag of
  87. /expire=grade5 means that this group will only be considered for expiry
  88. if the command-line flag -g5 or above is given.  The grading system
  89. works better with the -u option than the -t option, and you cannot use
  90. the /expire flag to set both a grade and a time limit for the same
  91. group. If you use -t regularly, consider setting large numerical values
  92. (like 300 days) for groups you want to protect, or using the -x switch.
  93.  
  94. ** Installing NUEXPIRE **
  95.  
  96. Place the NUEXPIRE.PL file in a directory such as /waffle/bin.  It is
  97. invoked with the command line
  98.  
  99. perl nuexpire.pl <flags>
  100.  
  101. where flags may be any of the following:
  102.  
  103. -t x    Expire time in days.  Expire all articles older than this figure.
  104.  
  105. -u name Expire according to the join file belonging to user 'name',
  106.         deleting all articles marked as read.  Only groups in the join
  107.         file will be expired.
  108.  
  109. -g x    Graded expire.  Expire only articles that are graded x or below,
  110.         provided that the article is older than the -t value or is
  111.         marked read in the -u join file. Newsgroups without /expire
  112.         flags and groups with numeric /expire flags are considered grade
  113.         1, and will always be considered for expiry.
  114.  
  115. -d      Debug mode.  Do not delete articles.  Instead, each newsgroup
  116.         definition line is printed to STDOUT, followed by any articles
  117.         that are to be expired from that group.  This flag is used when
  118.         you are tuning expire paramaters.  It's much easier than
  119.         expiring the news spool, inspecting the result, and then
  120.         restoring from a backup.  (besides, who backs up news?)
  121.  
  122. -l file Logfile name.  Specifying -l filename will append that filename
  123.         with the name of each article expired.  This is a
  124.         limited-usefulness flag, but if you want to maintain expiry
  125.         records, this will do it.  Since -l appends to the file, that
  126.         file can get very large, very fast.  You may want to read and
  127.         discard it on a regular basis.  The -l option is ignored if the
  128.         file cannot be opened.  If in debug mode, the file will not be
  129.         appended, but the filename will be shown in the options.
  130.  
  131. -x list Ignore this group.  Any number of groups can be listed after the
  132.         -x flag, and it need not be the last parameter.  Thus,
  133.         '-x alt.sources' would cause alt.sources not to be expired at
  134.         all this run, and '-x alt.*' would ignore the alt hierarchy.
  135.         This option is most useful to single-user Waffle installations.
  136.  
  137. -nuke   Expire all news in the news spool.  Replace highest-numbered
  138.         articles with 0-byte files.  The nuke option overrides all other
  139.         command-line options except debug.  Invoking nuke with debug
  140.         will give you a display of what nuke would have done, with D:
  141.         meaning delete, and T: meaning truncate.  You must confirm nuke
  142.         from the keyboard.
  143.  
  144. -autonuke   Same as nuke, but you don't get a chance to back out!
  145.  
  146. -s      Compile statistics of what news is on the spool.  This option,
  147.         like debug, does not delete articles.  Stats are written to
  148.         standard output, and may be redirected into a file.
  149.  
  150. Flags may be in any order, and the space between a flag and its argument
  151. is optional.  '-u fred' and '-ufred' will work interchangably.  You must
  152. specify either -t, -u or -s.
  153.  
  154. You may want to create a batchfile to run NUEXPIRE, and place that batch
  155. file in a directory on your path.  Then, NUEXPIRE will be available
  156. simply by typing the command.  Here is an example... edit paths to suit
  157. your system:
  158.  
  159. --- expire.bat ---
  160. c:\mybin\perl c:\waffle\bin\nuexpire.pl %1 %2 %3 %4 %5 %6 %7 %8 %9
  161. --- expire.bat ---
  162.  
  163. 4dos users can declare .pl as an executable extension with
  164.  
  165.     set .pl=c:\mybin\perl.exe
  166.  
  167. and invoke NUEXPIRE without further folderol
  168.  
  169.  
  170. ** Various information **
  171.  
  172. NUEXPIRE.PL, by Roy M. Silvernail, is released into the public domain.
  173. It is presented without any warranty.  If the universe explodes, or your
  174. mother-in-law moves in after using NUEXPIRE, it's your problem.
  175.  
  176. NUEXPIRE should work on virtually any size news spool.  Memory
  177. requirements have been reduced even below those of PEXPIRE and SUEXPIRE.
  178. NUEXPIRE will use slightly more memory with the -u flag, since the
  179. reference join file is loaded into an array.  In any case, though,
  180. NUEXPIRE is a Perl program, and the Perl interpreter itself is somewhat
  181. large.  NUEXPIRE may not run from within Waffle, and it's suggested that
  182. you run it from the RUN.BAT or manually from the command line.
  183.  
  184. NUEXPIRE was designed for MS-DOS systems.  While it could be used on a
  185. Unix system, you would have to edit the pathname munging in the fixpath
  186. subroutine.
  187.  
  188. NUEXPIRE is in daily use at cybrspc.  However, nobody is perfect.  If you
  189. discover a bug, or if you have a suggestion for improvement, please send
  190. a note to me at roy%cybrspc@cs.umn.edu.
  191.  
  192. Date of original release: 11/24/91
  193.