home *** CD-ROM | disk | FTP | other *** search
/ minnie.tuhs.org / unixen.tar / unixen / PDP-11 / Trees / V6 / usr / man / man6 / form.6 < prev    next >
Encoding:
Text File  |  1975-06-26  |  2.5 KB  |  72 lines

  1. .th FORM VI 6/15/72
  2. .sh NAME
  3. form \*- form letter generator
  4. .sh SYNOPSIS
  5. .bd form
  6. proto arg ...
  7. .sh DESCRIPTION
  8. .it Form
  9. generates a form letter from a prototype
  10. letter, an associative memory, arguments and in a special case, the
  11. current date.
  12. .s3
  13. If
  14. .it form
  15. is invoked with the
  16. .it proto
  17. argument \fIx\fR, the associative memory is
  18. searched for an entry with name \fIx\fR and the contents filed under that name are
  19. used as the prototype.
  20. If the search fails, the message `[\fIx\fR]:' is typed on
  21. the console and whatever text is typed in from the console, terminated by
  22. two new lines, is used as the prototype.
  23. If the prototype argument is missing, `{letter}' is assumed.
  24. .s3
  25. Basically,
  26. .it form
  27. is a copy process from the prototype to the output file.
  28. If an element of the form [\fIn\fR] (where \fIn\fR is a digit from 1 to 9) is encountered,
  29. the \fIn\fR-th
  30. .it arg
  31. is inserted in its place, and that argument is then
  32. rescanned.  If [0] is encountered, the current date is inserted.  If
  33. the desired argument has not been given, a message of the form `[\fIn\fR]:' is
  34. typed.
  35. The response typed in then is used for that argument.
  36. .s3
  37. If an element of the form [\fIname\fR] or {\fIname\fR} is encountered, the \fIname\fR is looked up in the
  38. associative memory.  If it is found, the contents of the memory under this
  39. \fIname\fR replaces the original element (again rescanned).  If
  40. the \fIname\fR is not found, a message of the form `[\fIname\fR]:' is typed.
  41. The response typed in is used for that element.  The response is
  42. entered in the memory under the name if the name is enclosed in [ ].
  43. The response is not entered in the memory but is remembered for the
  44. duration of the letter if the name is enclosed in {}.
  45. Brackets and braces may be nested.
  46. .s3
  47. In both of the above cases, the response is typed in by entering
  48. arbitrary text terminated by two new lines.  Only the first of the
  49. two new lines is passed with the text.
  50. .s3
  51. If one of the special characters [{]}\\ is preceded by
  52. a \\, it loses its special character.
  53. .s3
  54. If a file named `forma' already exists in the user's directory, `formb' is
  55. used as the output file and so forth to `formz'.
  56. .s3
  57. The file `form.m' is created if none exists.  Because form.m is
  58. operated on by the disc allocator, it should only be changed by using
  59. .it fed,
  60. the form letter editor, or
  61. .it form.
  62. .s3
  63. .sh FILES
  64. form.m    associative memory
  65. .br
  66. form?    output file (read only)
  67. .sh "SEE ALSO"
  68. fed (VI), roff (I)
  69. .sh BUGS
  70. An unbalanced ] or } acts as an end of file but
  71. may add a few strange entries to the associative memory.
  72.