home *** CD-ROM | disk | FTP | other *** search
/ Usenet 1994 January / usenetsourcesnewsgroupsinfomagicjanuary1994.iso / sources / misc / volume4 / mailsplit2 / undoc < prev   
Encoding:
Text File  |  1989-02-03  |  4.5 KB  |  98 lines

  1. Since I tore the comments out of the code, and it is not customary to send
  2. SCCS files around the net, I made this auxiliary file of documentation.
  3.  
  4. An alphabetical list of variables, their use and meaning:
  5.  
  6. AR = argument
  7. CM = command line
  8. CO = compress program may be arc, etc.
  9. DB = Debug level (Verbosity level)
  10. DE = Delay between pieces
  11. FC = file count
  12. FL = File list (build up file list from params on command line in
  13. FL = any order (see /usr/bin/spell) for a good example of obfuscated,
  14. FL = clever parsing code 
  15. LI = the number of lines to split pieces into
  16. MA = mail transport agent
  17. ME = the name of the program running
  18. MF = Mail flags to send to transport
  19. R  = range of pieces to be re-sent during parse stage
  20. RA = range of pieces to be re-sent if mailers on the way failed
  21. SE = send flag; if true, send the piece.  If false, don't
  22. SP = the name of the split program
  23. SU = subject of message  (defaults to first file name)
  24. T1 = temporary file containing output of tar and compress.
  25. T2 = temporary file containing uuencoded stuff
  26. T3 = temporary file(s) containing  split pieces
  27. TA = tar program (may be shar, tar, cat, etc ;-)
  28. TD = Temporary directory in which temp files should go can be . or /tmp.
  29. TM =  Test-mode flag (-n option of make)  Don't do anything, just
  30. TM = echo what you would have done if testmode option not on.
  31. TO = recipient(s) of message
  32. UU = the uuencode program (may be replaced with btoa / atob ;-)
  33. VE = version number
  34. f  = file name (piece) during loop which sends pieces
  35. i  = a loop index used during parse of the range of files to be re-sent
  36. max=  The loop-limit used in parse of range of files to be re-sent
  37. max= is assumed to be 99 if no top-of-range is given.
  38. n  = piece number during the loop which sends pieces via mail
  39. ne =  next param on command line (after flag is set, next param gets
  40. ne = eval'd to the var set in ne  (see above)
  41. t  = a specific token containing a range to be expanded (n-m)
  42. tok= Token during parse of range of files to be re-sent
  43.  
  44.  
  45. History:
  46. # Coder        Date      Comments
  47. #------------  -------- ---------------------------------------------------
  48. # M F Wyle     02nov87    Shamelessly stolen from tarmail :-)
  49. # WRU          18feb88    changed variable MAILER, added SPLITTER,
  50. #                         LINES, USER and a warning about uudecode
  51. # M F Wyle     25mar88    Add tar, extract join-script in 1st msg
  52. # WRU          03apr88  fixed some quoting problems in "echo"-strings
  53. #            cosmetic changes: renamed "mailsplit"
  54. #            created THISNAME
  55. #                       fixed some typos, added Email-addresses, example,
  56. #                       section for suggested improvements
  57. # MFW          05apr88  Fix more quoting problems in echo strings (shell
  58. #                       variables); added /bin/rm cleanup to join-script
  59. # MFW          21jun88  based on WRU's suggestions:
  60. #                       1) add file-name to subject
  61. #                       2) verbose explanations
  62. #                       3) add parts-order checking!  Yippeee!
  63. # MFW          08jul88  Fix uudecode setuid bug
  64. # MFW          12jul88  Fix empty or no files bug, added FILECOUNT
  65. # MFW          17jul88  Added umask 0, delay before mail, check after split
  66. # MFW          19jul88  Major re-write for flags, verbose, sccs control
  67. # MFW          25jul88  Added a range-parser, more flags, some documentation
  68. #                       Up'd release to 2.0 for distribution
  69.  
  70. Verbal description of algorithm:
  71. ====== =========== == ==========
  72. When the program starts, it initializes some variables, then parses the
  73. entire command line.  It builds up a list of non-flag options in the F
  74. variable.  The first parameter in F is the e-mail path.  All others are
  75. files or directories.
  76.  
  77. If no subject is set via the "-s subject"  flag, the subect is assigned
  78. from the first file to send.  The three temporary file names (variables
  79. T1, T2, and T3) are then assigned.
  80.  
  81. The range of pieces to be re-sent is parsed.
  82.  
  83. Debugging output is echo'd to standard out as appropriate for the
  84. debugging level.  If the -t or -n option is set, nothing is really
  85. done, except printing out what would have happened.
  86.  
  87. The tar, compress, split commands are performed, with appropriate
  88. verbosity for the debugging level.  Certain checks are made along the
  89. way to verify that the commands did not fail.  If one fails, the
  90. program exits with an appropriate failure message.
  91.  
  92. The files created in $T3* are sent via mail one at a time, with
  93. delays.  The first file sent has a join-script pre-pended.  A file
  94. counter $n is used to label the subject lines.
  95.  
  96. The temporary files are deleted.
  97.  
  98.