1 .\" This file is automatically generated. Do not edit!
2 .\" @(#)$Id: MH.rf,v 1.30 1995/12/06 01:27:51 jromine Exp $
4 .de $c \" Major Heading printer
6 .b "\\s12\\n+(ch.\\ \\$1\\s0" \" 12 Point Bold Header
9 \ \ \ \\n(ch.\\ \\ \\$1
11 .sp 45p \" 45 point space or about 1/2 inch
13 \".nr xs .15v \" Put index entries closer together
18 .de $0 \" Sub-Heading macro called AFTER printing the heading
25 .de $s \" Macro to print footnote separator
26 \"\l'2i' \" No line drawn
28 . sp 1.3 \" But extra space to make up for it.
30 .fc ^ ~ \" The characters ^ and ~ CANNOT BE USED
31 \" throughout this document except as field
32 \" delimiter & pad indicator!
34 .ll 32P \" 32 Picas or about 5+1/3 inch Line Length
35 .if n .ll 72m \" Use 72 ems for nroff
36 .nr ss 30p \" 30 point space before section titles
37 .nr fm 5v \" RAND likes bigger than normal [3v] bottom margins
39 .ds . \\fB.\\fP\\h'-(1m/3)' \" Bold period to stand out.
40 .ds << <\\h!-(\\w'<'/2)!<
41 .ds >> >\\h!-(\\w'>'/2)!>
42 .ds ** \v'-3p'\s+1*\s0\v'+3p'
46 \fIdiscard this page\fR
49 Message Handling System:
60 Although people can travel cross-country in hours and can
61 reach others by telephone in seconds, communications still depend
62 heavily upon paper, most of which is distributed through the mails.
64 There are several major reasons for this continued dependence on
66 First, a written document may be proofread
67 and corrected prior to its distribution, giving the author
68 complete control over his words.
69 Thus, a written document is
70 better than a telephone conversation in this respect.
72 a carefully written document is far less likely to be
73 misinterpreted or poorly translated than a phone conversation.
74 Third, a signature offers reasonable verification of authorship,
75 which cannot be provided with media such as telegrams.
79 accurate, and reproducible document distribution is
81 One solution in widespread use is the telefax.
83 that is rapidly gaining popularity is electronic mail.
84 Electronic mail is similar to telefax in that the data to be sent
85 are digitized, transmitted via phone lines, and
86 turned back into a document at the receiver.
88 electronic mail is in its compression factor.
90 must scan a page in very fine lines and send all of the black and
91 white information, electronic mail assigns characters fixed
92 codes which can be transmitted as a few bits of information.
93 Telefax presently has the advantage of being able to transmit an
94 arbitrary page, including pictures, but electronic mail is
95 beginning to deal with this problem.
96 Electronic mail also integrates well
97 with current directions in office automation, allowing documents
98 prepared with sophisticated equipment at one site to be quickly
99 transferred and printed at another site.
101 Currently, most electronic mail is intraorganizational,
102 with mail transfer remaining within one computer.
104 networking becomes more common, however, it is becoming more feasible to
105 communicate with anyone whose computer can be linked to your
108 The pioneering efforts on general-purpose electronic mail
109 were by organizations using the DoD ARPAnet[1].
110 The capability to send messages between computers existed before
111 the ARPAnet was developed, but it was used only in limited ways.
112 With the advent of the
113 ARPAnet, tools began to be developed which made it convenient for
114 individuals or organizations to distribute messages
115 over broad geographic areas, using
116 diverse computer facilities.
117 The interest and activity in
118 message systems has now reached such proportions that steps
119 have been taken within the DoD to coordinate and
120 unify the development of military message systems.
121 The use of electronic mail is expected to increase
122 dramatically in the next few years.
123 The utility of such systems
124 in the command and control and intelligence environments is
125 clear, and applications in these areas will probably lead the
127 As the costs for sending and handling electronic messages
128 continue their rapid decrease, such uses can be
129 expected to spread rapidly into other areas and, of course, will
130 not be limited to the DoD.
132 A message system provides tools that help users (individuals
133 or organizations) deal with messages in various ways.
135 must be composed, sent, received, stored, retrieved,
136 forwarded, and replied to.
137 Today's best interactive computer
138 systems provide a variety of word-processing and information
139 handling capabilities.
140 The message handling facilities should be
141 well integrated with the rest of the system, so as to be a
142 graceful extension of overall system capability.
144 The message system described in this report, \fIMH\fR, provides most of the
145 features that can be found in other message systems and also
146 incorporates some new ones.
147 It has been built on the UNIX time-sharing
148 system[2], a popular operating system for the DEC PDP-11\**
149 and VAX-11 classes of computers.
151 \** PDP and VAX are trademarks of Digital Equipment Corporation.
153 A \*(lqsecure\*(rq operating
154 system similar to UNIX is currently being developed[3],
155 and that system will also run \fIMH\fR.
157 This report provides a complete description of \fIMH\fR and
158 thus may serve as a user's manual, although parts of the report
159 will be of interest to non-users as well.
160 Sections 2 and 3, the
161 Overview and Tutorial, present the key
162 ideas of \fIMH\fR and will give those not familiar with message systems
163 an idea of what such systems are like.
165 \fIMH\fR consists of a set of commands which use some special
166 files and conventions.
167 The final section is divided into three parts.
168 The first part covers the information
169 a user needs to know in addition to the
171 Then, each of the \fIMH\fR commands is described in detail.
172 Finally, other obscure details are revealed.
173 A summary of the commands is given in Appendix A,
174 and the syntax of message sequences is given in Appendix B.
176 A novel approach has been taken in the design of \fIMH\fR.
177 Instead of creating a large subsystem that appears as a single
178 command to the user (such as MS[4]),
179 \fIMH\fR is a collection of separate commands
180 which are run as separate programs.
181 The file and directory
182 system of UNIX are used directly.
183 Messages are stored as
184 individual files (datasets), and collections of them are grouped
186 In contrast, most other message systems store
187 messages in a complicated data structure within a monolithic
189 With the \fIMH\fR approach, UNIX commands can be
190 interleaved with commands invoking the functions of the message
192 Conversely, existing UNIX commands
193 can be used in connection with messages.
195 example, all the usual UNIX editing, text-formatting, and printing
196 facilities can be applied directly to individual messages.
198 therefore, consists of a relatively small amount of new code; it
199 makes extensive use of other UNIX software to provide the
200 capabilities found in other message systems.
203 There are three main aspects of \fIMH\fR\0: the way messages are
204 stored (the message database), the user's profile (which directs
205 how certain actions of the message handler take place), and the
206 commands for dealing with messages.
208 Under \fIMH\fR, each message is stored as a separate file.
210 can take any action with a message that he could with an ordinary
212 A UNIX directory in which messages are stored is
214 Each folder contains some standard entries to support
215 the message-handling functions.
216 The messages in a folder have numerical
218 These folders (directories)
219 are entries in a particular directory path, described in
220 the user profile, through which \fIMH\fR can find message folders.
221 Using the UNIX \*(lqlink\*(rq facility, it is possible for one copy of a
222 message to be \*(lqfiled\*(rq in more than one folder, providing a
223 message index facility.
224 Also, using the UNIX tree-structured
225 file system, it is possible to have a folder within a folder,
226 nested arbitrarily deep,
227 and have the full power of the \fIMH\fR commands available.
229 Each user of \fIMH\fR has a user profile, a file in
230 his \fB$HOME\fR (initial login) directory called \fI\&.mh\(ruprofile\fR.
231 This profile contains several
232 pieces of information used by the \fIMH\fR commands:
233 a path name to the directory that contains the message folders
234 and parameters that tailor \fIMH\fR commands
235 to the individual user's requirements.
236 There is also another file,
237 called the user context,
238 which contains information concerning which folder the user last referenced
239 (the \*(lqcurrent\*(rq folder).
241 most of the necessary state information concerning how
242 the user is dealing with his messages, enabling \fIMH\fR to be
243 implemented as a set of individual UNIX commands, in contrast to the
244 usual approach of a monolithic subsystem.
246 In \fIMH\fR, incoming mail is appended
247 to the end of a file in a system spooling area for the user.
248 This area is called the mail drop directory,
249 and the file is called the user's mail drop.
250 Normally when the user logins in,
251 s/he is informed of new mail
252 (or the \fIMH\fR program \fImsgchk\fR may be run).
253 The user adds the new messages to his/her collection of \fIMH\fR messages
254 by invoking the command
256 The \fIinc\fR (incorporate) command adds the new
257 messages to a folder called \*(lqinbox\*(rq, assigning them names which
258 are consecutive integers starting with the next highest integer
260 \fIinc\fR also produces a
261 \fIscan\fR summary of
262 the messages thus incorporated.
263 A folder can be compacted into a single file,
265 by using the \fIpackf\fR command.
267 messages within a folder can be sorted by date and time with the \fIsortm\fR
271 There are four commands for examining the messages in a
278 The \fIshow\fR command displays a message in a folder,
279 \fIprev\fR displays the message preceding the current message, and
280 \fInext\fR displays the message following the current message.
281 \fIMH\fR lets the user choose the program that displays individual messages.
282 A special program, \fImhl\fR, can be used to display messages according
283 to the user's preferences.
284 The \fIscan\fR command summarizes the messages in a folder,
285 normally producing one line per message, showing who the message is from,
286 the date, the subject, etc.
288 The user may move a message from one folder to another with
291 Messages may be removed from a folder
292 by means of the command
294 In addition, a user may query
295 what the current folder is and may specify that a new folder
296 become the current folder, through the command
298 All folders may be summarized with the \fIfolders\fR command.
299 A message folder (or subfolder) may be removed by means of
303 A set of messages based on content may be selected by
304 use of the command \fIpick\fR.
305 This command searches through
306 messages in a folder and selects those that match a given
308 These messages are then bound to a \*(lqsequence\*(rq name for use with other
310 The \fImark\fR command manipulates these sequences.
312 There are five commands enabling the user to create new
313 messages and send them:
320 The \fIcomp\fR command
321 provides the facility for the user to compose a
323 \fIdist\fR redistributes mail to additional addressees;
324 \fIforw\fR enables the user to forward messages; and
325 \fIrepl\fR facilitates the generation of a reply to an incoming message.
326 The last three commands may optionally annotate the original message.
327 Messages may be arbitrarily annotated with the \fIanno\fR command.
328 Once a draft has been constructed by one of the four above composition
330 a user\-specifiable program is run to query the user as to the disposition of
331 the draft prior to sending.
332 \fIMH\fR provides the simple \fIwhatnow\fR program to start users off.
334 a message is not sent directly by one of these commands, it may
335 be sent at a later time using the command
337 \fIMH\fR allows the use of any UNIX editor when composing a message.
338 For rapid entry, a special editor, \fIprompter\fR, is provided.
339 For programs, a special mail-sending program, \fImhmail\fR, is provided.
341 \fIMH\fR supports a personal aliasing facility which gives users the
342 capability to considerably shorten address typein
343 and use meaningful names for addresses.
344 The \fIali\fR program can be used to query \fIMH\fR as to the expansion of a
346 After composing a message, but prior to sending, the \fIwhom\fR command
347 can be used to determine exactly who a message would go to.
349 \fIMH\fR provides a natural interface for telling the user's shell the names
350 of \fIMH\fR messages and folders.
351 The \fImhpath\fR program achieves this capability.
353 The \fIburst\fR command can be used to \*(lqshred\*(rq digests of messages
354 into individual messages.
356 All of the elements summarized above
357 are described in more detail in the following sections.
359 normal facilities of UNIX provide additional capabilities for
360 dealing with messages in various ways.
362 possible to print messages
363 on the line-printer without requiring any additional code within
365 Using standard UNIX facilities, any terminal output can be
366 redirected to a file for repeated or future viewing.
368 the flexibility and capabilities of the UNIX interface with the
369 user are preserved as a result of the integration of \fIMH\fR into the UNIX
373 This tutorial provides a brief introduction to the \fIMH\fR commands.
374 It should be sufficient
375 to allow the user to read his mail, do some simple manipulations of
376 it, and create and send messages.
378 A message has two major pieces: the
380 The body consists of the text of the message
381 (whatever you care to type in).
382 It follows the header and is separated from
384 (When you compose a message, the form that appears
385 on your terminal shows a line of dashes after the header.
387 convenience and is replaced by an empty line when the message is
388 sent.) The header is composed of several components, including the
389 subject of the message and the person to whom it is addressed.
390 Each component starts with a name
391 and a colon; components must not start with a blank.
393 component may take more than one line, but each continuation line must
395 Messages typically have \*(lqTo:\*(rq, \*(lqcc:\*(rq, and
396 \*(lqSubject:\*(rq components.
397 When composing a message, you should include
398 the \*(lqTo:\*(rq and \*(lqSubject:\*(rq components;
399 the \*(lqcc:\*(rq (for people you want to send copies to) is not necessary.
401 The basic \fIMH\fR commands are
411 These are described below.
415 When you get the message \*(lqYou have mail\*(rq, type the command \fIinc\fR.
416 You will get a \*(lqscan listing\*(rq such as:
420 .ta \w'7+ 'u +\w'11/26 'u +\w'To:norm 'u
421 7+ \07/13 Cas revival of measurement work
422 8 10/\09 Norm NBS people and publications
423 9 11/26 To:norm question \*(<<Are there any functions
428 This shows the messages you received since the last time you
429 executed this command (\fIinc\fR adds these new messages to your inbox folder).
430 You can see this list again, plus a list of any
431 other messages you have, by using the
436 The scan listing shows the message number, followed by the
438 (If you are the sender, the addressee in the \*(lqTo:\*(rq
439 component is displayed.
440 You may send yourself a message by including
441 your name among the \*(lqTo:\*(rq or \*(lqcc:\*(rq addressees.)
442 It also shows the message's subject; if
443 the subject is short, the first part of the body of the message is
444 included after the characters \*(<<.
449 This command shows the current message, that is,
450 the first one of the new messages after an
452 If the message is not
453 specified by name (number), it is
454 generally the last message referred to by an \fIMH\fR command.
458 .ta \w'\fIshow\fR\0|\0\fIlpr\fR 'u
460 ^\fIshow\fP\05~^will show message 5.
464 You can use the show command to copy a message or print a
469 .ta \w'\fIshow\fR\0|\0\fIlpr\fR 'u
470 ^\fIshow\fR\0>\0\fIx\fR~^will copy the message to file x.
472 ^\fIshow\fR\0|\0\fIlpr\fR~^will print the message, using the \fIlpr\fR command.
474 ^\fInext\fR~^will show the message that follows the current message.
476 ^\fIprev\fR~^will show the message previous to the current message.
478 ^\fIrmm\fR~^will remove the current message.
480 ^\fIrmm\03\fR~^will remove message 3.
487 \fIcomp\fR command puts you in the editor to write or edit a message.
489 delete the \*(lqTo:\*(rq, \*(lqcc:\*(rq, and \*(lqSubject:\*(rq fields,
490 as appropriate, and type the body of the message.
492 exit normally from the editor.
495 Type a carriage return to see the options.
497 will cause the message to be sent; typing \fBquit\fR will cause an exit
500 with the message draft saved.
502 If you quit without sending the message, it will be saved in a file
503 called <name>/Mail/draft (where <name> is your \fB$HOME\fR directory).
504 You can resume editing the message later with \*(lqcomp\0\-use\*(rq;
505 or you can send the message later, using the \fIsend\fR command.
508 \fIcomp\0\-editor\0prompter\fR
510 This command uses a different editor and is useful for preparing
511 \*(lqquick and dirty\*(rq messages.
512 It prompts you for each component of the
514 Type the information for that component, or type a carriage
515 return to omit the component.
516 After that, type the body of the
518 Backspacing is the only form of editing allowed with this editor.
519 When the body is complete, type a carriage return followed by <EOT>
521 This completes the initial preparation of the message; from then on, use
522 the same procedures as with
530 This command makes up an initial message form with a header
531 that is appropriate for
532 replying to an existing message.
533 The message being answered is the
534 current message if no message number is mentioned, or n if a number
536 After the header is completed, you can finish the message as in
539 This is enough information to get you going using \fIMH\fR.
540 There are more commands,
541 and the commands described here have more features.
543 explain \fIMH\fR in complete detail.
544 The system is quite powerful if you
545 want to use its sophisticated features, but the foregoing commands
546 suffice for sending and receiving messages.
548 There are numerous additional capabilities you may wish to explore.
550 \fIpick\fR command will select a subset of messages
551 based on specified criteria such as sender and/or subject.
553 messages may be designated, as described in Sec. IV,
554 under \fBMessage Naming\fR.
555 The file \fI\&.mh\(ruprofile\fR can be used to tailor your use of
556 the message system to your needs and preferences, as described in Sec. IV,
557 under \fBThe User Profile\fR.
559 learn additional features of the system selectively, according to your
561 by studying the relevant sections of this manual.
563 learn all the details of the system at once.
564 .+c "DETAILED DESCRIPTION"
566 This section describes the \fIMH\fR system in detail, including the components
567 of the user profile, the conventions for message naming, and some of
568 the other \fIMH\fR conventions.
570 generally familiar with computer systems will be able to follow
571 the principal ideas, although some details may be meaningful only to
572 those familiar with UNIX.
573 .uh "THE USER PROFILE"
575 The first time an \fIMH\fR command is issued by a new user, the system
576 prompts for a \*(lqPath\*(rq and creates an \fIMH\fR \*(lqprofile\*(rq.
578 Each \fIMH\fR user has a profile which contains tailoring
579 information for each individual program.
580 Other profile entries control the \fIMH\fR path (where folders and
581 special files are kept), folder and message protections, editor
582 selection, and default arguments for each \fIMH\fR program.
583 Each user of \fIMH\fR also has a context file which contains
584 current state information for the \fIMH\fR package
585 (the location of the context file is kept in the user's \fIMH\fR directory,
586 or may be named in the user profile).
587 When a folder becomes
588 the current folder, it is recorded in the user's context.
589 (Other state information is kept in the context file,
590 see the manual entry for \fImh\-profile\0\fR(5) for more details.)
592 the term \*(lqprofile entry\*(rq refer to entries in either the profile or
594 Users of \fIMH\fR needn't worry about the distinction,
595 \fIMH\fR handles these things automatically.
597 The \fIMH\fR profile is stored in the file \fI\&.mh\(ruprofile\fR in the
598 user's \fB$HOME\fR directory\**.
600 \** By defining the envariable \fB$MH\fR,
601 you can specify an alternate profile to be used by \fIMH\fR commands.
603 It has the format of a message without
605 That is, each profile entry is on one line, with a
606 keyword followed by a colon (:) followed by text particular to
610 \fIThis file must not have blank lines.\fR
613 may have any combination of upper and lower case.
614 (See the information of \fImh\-mail\fR later on in this manual
615 for a description of message formats.)
617 For the average \fIMH\fR user, the only profile entry of
618 importance is \*(lqPath\*(rq.
619 Path specifies a directory in which \fIMH\fR
620 folders and certain files such as \*(lqdraft\*(rq are found.
622 argument to this keyword must be a legal UNIX path that names an
624 If this path is not absolute
625 (i.e., does not begin with a \fB/\fR\0),
626 it will be presumed to start from the user's \fB$HOME\fR directory.
627 All folder and message references within
628 \fIMH\fR will relate to this path unless full path names are used.
630 Message protection defaults to 644, and folder protection to
632 These may be changed by profile entries \*(lqMsg-Protect\*(rq
633 and \*(lqFolder-Protect\*(rq, respectively.
634 The argument to these
635 keywords is an octal number which is used as the UNIX file mode\**.
637 \** See \fIchmod\fR\0(1) in the \fIUNIX Programmer's Manual\fR\0[5].
640 When an \fIMH\fR program starts running, it looks through the
641 user's profile for an entry with a keyword matching the program's
644 \fIcomp\fR is run, it looks for a \*(lqcomp\*(rq
646 If one is found, the text of the profile entry is
647 used as the default switch setting until all defaults are overridden
648 by explicit switches passed to the program as arguments.
650 entry \*(lqcomp:\0\-form\0standard.list\*(rq would direct
651 \fIcomp\fR to use the
652 file \*(lqstandard.list\*(rq as the message skeleton.
654 form switch is given to the
655 \fIcomp\fR command, it will override the
656 switch obtained from the profile.
658 In UNIX, a program may exist under several names,
659 either by linking or aliasing.
660 The actual invocation name is used by an \fIMH\fR
661 program when scanning for its profile defaults\**.
664 the shell does not preserve aliasing information when calling a program,
665 hence if a program is invoked by an alias different than its name,
666 the program will examine the profile entry for it's name,
667 not the alias that the user invoked it as.
668 The correct solution is to create a (soft) link in your \fI$HOME/bin\fR
669 directory to the \fIMH\fR program of your choice.
670 By giving this link a different name,
671 you can use an alternate set of defaults for the command.
673 Thus, each \fIMH\fR program
674 may have several names by which it can be invoked, and each name
675 may have a different set of default switches.
677 \fIcomp\fR is invoked by the name
680 \*(lqicomp\*(rq will control the default switches for this invocation of
683 This provides a powerful
684 definitional facility for commonly used switch settings.
693 is usually \fIprompter\fR,
694 but might be something else at your site,
695 such as \fI/usr/ucb/ex\fR or \fI/bin/e\fR.
696 A different editor may be used by specifying
699 The argument to \*(lqEditor\*(rq is the name of an
700 executable program or shell command file which can be found via
701 the user's $PATH defined search path, excluding the current
703 The \*(lqEditor:\*(rq profile specification
704 may in turn be overridden by a `\-editor\0<editor>'
705 profile switch associated with
711 Finally, an explicit editor switch specified with any
712 of these four commands will have ultimate precedence.
714 During message composition, more than one editor may be
716 For example, one editor (such as \fIprompter\fR\0)
718 initially, and a second editor may be invoked later to revise
719 the message being composed
720 (see the discussion of
721 \fIcomp\fR in Section 5 for details).
722 A profile entry \*(lq<lasteditor>\-next:\0<editor>\*(rq specifies the name of
723 the editor to be used after a particular editor.
724 Thus \*(lqcomp:\0\-e\0prompter\*(rq
725 causes the initial text to be collected by
727 and the profile entry \*(lqprompter\-next:\0ed\*(rq names ed as the
728 editor to be invoked for the next round of editing.
730 Some of the \fIMH\fR commands, such as
733 message folders owned by others, if those folders are readable.
735 you cannot write in someone else's folder.
736 All the \fIMH\fR command
737 actions not requiring write permission may be used with
738 a \*(lqread-only\*(rq folder.
740 Table 1 lists examples of some of the currently defined profile
741 entries, typical arguments, and the programs that reference the
746 .ta \w'<program>:\0default switches 'u
752 P\s-2ROFILE\s0 C\s-2OMPONENTS\s0
753 .hl \" ~12p preceding + 1v (12p) after
755 ^^\fIMH\fR Programs that
756 ^Keyword and Argument~^\ use Component\h'|\n(.lu-.9i'\v'4p'\l'|0'\v'-4p' \" \l'..' does underlining
759 ^Current-Folder:\0inbox~^Most
760 ^Editor:\0/usr/ucb/ex~^\fIcomp, dist, forw, repl\fR
761 ^Inbox:\0inbox~^\fIinc, rmf\fR
762 ^Msg\-Protect:\0644~^\fIinc\fR
763 ^Folder\-Protect:\0711~^\fIinc, pick, refile\fR
764 ^<program>:\0default switches~^All
765 ^prompter\-next:\0ed~^\fIcomp, dist, forw, repl\fR
774 Current\-Folder is maintained
775 automatically by many \fIMH\fR commands (see the \fBContext\fR sections of
776 the individual commands in Sec. IV).
777 All other entries are optional,
778 defaulting to the values described above.
781 Messages may be referred to explicitly or implicitly when
782 using \fIMH\fR commands.
783 A formal syntax of message names is given in Appendix B, but the
784 following description should be sufficient for most \fIMH\fR users.
785 Some details of message naming that apply only to certain
786 commands are included in the description of those
789 Most of the \fIMH\fR commands accept arguments specifying one or
790 more folders, and one or more messages to operate on.
792 the word \*(lqmsg\*(rq as an argument to a command means that exactly one
793 message name may be specified.
794 A message name may be a number,
795 such as 1, 33, or 234, or it may be
796 one of the \*(lqreserved\*(rq message names:
797 first, last, prev, next, and cur.
799 period (\&.) is equivalent to cur.)
800 The meanings of these names are straightforward:
801 \*(lqfirst\*(rq is the first message in the folder;
802 \*(lqlast\*(rq is the last message in the folder;
803 \*(lqprev\*(rq is the message numerically previous to the current message;
804 \*(lqnext\*(rq is the message numerically following the current message;
805 \*(lqcur\*(rq (or \*(lq\&.\*(rq) is the current message in the folder.
807 \fIMH\fR supports user\-defined\-sequences;
808 see the description of the \fImark\fR command for more information.
810 The default in commands that take a \*(lqmsg\*(rq argument is
811 always \*(lqcur\*(rq.
813 The word \*(lqmsgs\*(rq indicates that several messages may be
815 Such a specification consists of several message
816 designations separated by spaces.
817 A message designation is
818 either a message name or a message range.
820 specification of the form name1\-name2 or name1:n, where name1 and
821 name2 are message names and n is an integer.
823 designates all the messages from name1 to name2 inclusive; this
824 must be a non-empty range.
825 The second form specifies up to n
826 messages, starting with name1 if name1 is a number, or first,
827 cur, or next, and ending with name1 if name1 is last or
829 This interpretation of n is overridden if n is preceded
830 by a plus sign or a minus sign;
831 +n always means up to n messages starting with
832 name1, and \-n always means up to n messages ending with name1.
833 Repeated specifications of the same message have the same effect
834 as a single specification of
846 The message name \*(lqall\*(rq is a shorthand for \*(lqfirst\-last\*(rq,
847 indicating all of the messages in the folder.
849 In commands that accept \*(lqmsgs\*(rq arguments, the default is
850 either cur or all, depending on which makes more sense.
852 In all of the \fIMH\fR commands, a plus sign preceding an argument
853 indicates a folder name.
854 Thus, \*(lq+inbox\*(rq is the name of the
855 user's standard inbox.
856 If an explicit folder argument is given
857 to an \fIMH\fR command, it will become the current folder (that is,
858 the \*(lqCurrent-Folder:\*(rq entry
859 in the user's profile will be changed to this folder).
861 \fIrefile\fR command, which
862 can have multiple output folders, a new source folder (other than
863 the default current folder) is specified by `\-src\0+folder'.
864 .uh "OTHER MH CONVENTIONS"
866 One very powerful feature of \fIMH\fR is that the \fIMH\fR commands may
867 be issued from any current directory, and the proper path to
868 the appropriate folder(s) will be taken from the user's profile.
869 If the \fIMH\fR path is not appropriate for a specific folder or file,
870 the automatic prepending of the \fIMH\fR path can be avoided by
871 beginning a folder or file name with \fB/\fR,
872 or with \fB\&./\fR or \fB\&.\&./\fR component.
873 Thus any specific absolute path may be specified along with any path
874 relative to the current working directory.
876 Arguments to the various programs may be given in any order,
877 with the exception of a few switches whose arguments must follow
878 immediately, such as `\-src\0+folder' for \fIrefile\fR.
880 Whenever an \fIMH\fR command prompts the user, the valid options
881 will be listed in response to a <RETURN>.
883 listed options is the default if end-of-file is encountered,
884 such as from a command file.)
885 A valid response is any \fIunique\fR abbreviation of one of the listed options.
887 Standard UNIX documentation conventions are used in this report
888 to describe \fIMH\fR command syntax.
889 Arguments enclosed in brackets
890 ([ ]) are optional; exactly one of the arguments enclosed
891 within braces ({ }) must be specified, and all other
892 arguments are required.
893 The use of ellipsis dots (...) indicates
894 zero or more repetitions of the previous item.
896 \*(lq+folder ...\*(rq would indicate that one or more \*(lq+folder\*(rq
897 arguments is required
898 and \*(lq[+folder ...]\*(rq indicates that 0 or more
899 \*(lq+folder\*(rq arguments may be given.
901 \fIMH\fR departs from UNIX standards by using switches that consist of
902 more than one character, e.g. `\-header'.
904 only a unique abbreviation of a switch need be typed; thus, for
905 `\-header', `\-hea' is probably sufficient, depending on the
906 other switches the command accepts.
907 Each \fIMH\fR program
908 accepts the switch `\-help' (which \fBmust\fR be spelled out fully)
909 and produces a syntax description and a list of switches.
911 list of switches, parentheses indicate required characters.
912 For example, all `\-help' switches will appear as \*(lq\-(help)\*(rq,
913 indicating that no abbreviation is accepted.
915 the `\-help' switch tells the version of the \fIMH\fR program you invoked.
917 Many \fIMH\fR switches have both on and off forms, such as
918 `\-format' and `\-noformat'.
919 In many of the descriptions which follow,
920 only one form is defined; the other form, often used to
921 nullify profile switch settings, is assumed to be the opposite.
926 The \fIMH\fR package comprises several programs:
927 .\" I pity the fool who tampers with the next line...
931 These programs are described below.
932 The form of the descriptions
933 conforms to the standard
934 form for the description of UNIX commands.
939 .fo '[mh.6]'MH.6.8'UCI version'
941 .he '\\$1(\\$2)'-%-'\\$1(\\$2)'
963 .b \\s-2DESCRIPTION\\s0
980 .b "\\s-2Helpful Hints\\s0"
989 .ta \w'/opt/mh-6.8.5/lib/ExtraBigFileName 'u
994 .ta \w'ExtraBigProfileName 'u
996 .b "\\s-2Profile Components\\s0"
1006 .b "\\s-2See Also\\s0"
1014 .b \\s-2Defaults\\s0
1090 This section describes some of the more intense points of the \fIMH\fR system,
1091 by expanding on topics previously discussed.
1092 The format presented conforms to the standard form for the description of UNIX
1098 .fo '[mh.6]'MH.6.8'UCI version'
1119 .+c "REPORTING PROBLEMS"
1121 If problems are encountered with an \fIMH\fR program,
1122 the problems should be reported to the local maintainers of \fIMH\fR.
1124 the name of the program should be reported,
1125 along with the version information for the program.
1126 To find out what version of an \fIMH\fR program is being run,
1127 invoke the program with the `\-help' switch.
1128 In addition to listing the syntax of the command,
1129 the program will list information pertaining to its version.
1130 This information includes the version of \fIMH\fR,
1131 the host it was generated on,
1132 and the date the program was loaded.
1133 A second line of information,
1134 found on versions of \fIMH\fR after #5.380 include \fIMH\fR configuration
1139 version: MH 6.1 #1[UCI] (nrtc-gremlin) of Wed Nov 6 01:13:53 PST 1985
1141 options: [BSD42] [MHE] [NETWORK] [SENDMTS] [MMDFII] [SMTP] [POP]
1144 The `6.1 #1[UCI]' indicates that the program is from the UCI \fImh.6\fR
1145 version of \fIMH\fR.
1146 The program was generated on the host `nrtc-gremlin' on
1147 `Wed Nov 6 01:13:53 PST 1985'.
1148 It's usually a good idea to send the output of the `\-help' switch along
1151 If there is no local \fIMH\fR maintainer,
1152 try the address \fBBug-MH\fR.
1153 If that fails, use the Internet mailbox \fBBug-MH@ICS.UCI.EDU\fR.
1155 .+c "ADVANCED FEATURES"
1166 This section describes some features of \fIMH\fR that were included strictly
1167 for advanced \fIMH\fR users.
1168 These capabilities permit \fIMH\fR to exhibit more powerful behavior for the
1169 seasoned \fIMH\fR users.
1170 .uh "USER\-DEFINED SEQUENCES"
1172 User\-defined sequences allow the \fIMH\fR user a tremendous amount of power
1173 in dealing with groups of messages in the same folder
1174 by allowing the user to bind a group of messages to a meaningful symbolic
1176 The user may choose any name for a message sequence,
1177 as long as it consists of alphanumeric characters and does not conflict with
1178 the standard \fIMH\fR reserved message names
1179 (e.g., \*(lqfirst\*(rq, etc).
1180 After defining a sequence,
1181 it can be used wherever an \fIMH\fR command expects a `msg' or `msgs'
1184 A restricted form of message ranges are allowed with user\-defined
1185 sequences. The form \*(lqname:n\*(rq, specifies up to the first `n' messages
1186 which are part of the user\-defined sequence `name'.
1187 A leading plus sign is allowed on `n', but is ignored.
1188 The interpretation of n is overridden if n is preceded
1190 `\-n' always means up to the last `n' messages which are part of the
1193 Although all \fIMH\fR commands expand user\-defined sequences as appropriate,
1194 there are two commands that allow the user to define and manipulate them:
1195 \fIpick\fR and \fImark\fR.
1196 .UH "Pick and User\-Defined Sequences"
1198 Most users of \fIMH\fR will use user\-defined sequences only with
1199 the \fIpick\fR command.
1200 By giving the `\-sequence\ name' switch to \fIpick\fR
1201 (which can occur more than once on the command line),
1202 each sequence named is defined as those messages which \fIpick\fR matched
1203 according the the selection criteria it was given.
1207 pick\0\-from\0frated\0\-seq\0fred
1209 finds all those messages in the current folder which were from
1211 creates a sequence called \*(lqfred\*(rq,
1212 and then adds them to the sequence.
1213 The user could then invoke
1218 to get a \fIscan\fR listing of those messages.
1219 Note that by default,
1220 \fIpick\fR creates the named sequences
1221 before it adds the selected messages to the sequence.
1222 Hence, if the named sequence already existed,
1223 the sequence is destroyed prior to being re-defined
1224 (nothing happens to the messages that were a part of this sequence,
1225 they simply cease to be members of that sequence).
1226 By using the `\-nozero' switch, this behavior can be inhibited,
1230 pick\0\-from\0frated\0\-seq\0sgroup
1232 pick\0\-from\0fear\0\-seq\0sgroup\0\-nozero
1234 pick\0\-from\0freida\0\-seq\0sgroup\0\-nozero
1237 finds all those messages in the current folder which were from
1238 \*(lqfrated\*(rq, \*(lqfear\*(rq, or \*(lqfreida\*(rq,
1239 and defines the sequence called \*(lqsgroup\*(rq as exactly those messages.
1240 These operations amounted to an \*(lqinclusive\-or\*(rq of three selection
1243 one can also generate the \*(lqand\*(rq of some selection criteria as well:
1246 pick\0\-from\0frated\0\-seq\0fred
1248 pick\0\-before\0friday\0\-seq\0fred\0fred
1251 This example defines the sequence called \*(lqfred\*(rq as exactly those
1252 messages from \*(lqfrated\*(rq that were dated prior to \*(lqfriday\*(rq.\**
1255 it is much easier to simply use the built\-in boolean operation of
1256 \fIpick\fR to get the desired results:
1259 pick\0\-from\0frated\0\-or\0\-from\0fear\0\-or\0\-from\0freida\0\-seq\0sgroup
1264 pick\0\-from\0frated\0\-and\0\-before\0friday\0\-seq\0fred
1266 do exactly the same thing as the five commands listed above.
1267 Hence, the `\-nozero' option to \fIpick\fR is only useful to manipulate
1271 \fIPick\fR is normally used as a back\-quoted command,
1275 scan\0`pick\0\-from\0postmaster`
1277 Now suppose that the user decides that another command should be issued,
1278 using exactly those messages.
1280 \fIpick\fR wasn't given a `\-sequence\ name' argument in this example,
1281 the user would end\-up typing the entire back\-quoted command again.
1282 A simpler way is to add a default sequence name to the \&.mh\(ruprofile.
1286 pick:\0\-seq\0select\0\-list
1288 will tell \fIpick\fR to always define the sequence \*(lqselect\*(rq whenever
1290 The `-list' is necessary since the `\-sequence\ name' switch sets `\-nolist'
1291 whenever the former is encountered.
1292 Hence, this profile entry makes \fIpick\fR define the \*(lqselect\*(rq
1293 sequence and otherwise behave exactly as if there was no profile entry at all.
1294 .UH "Mark and User\-Defined Sequences"
1296 The \fImark\fR command lets the user perform low\-level manipulation of
1298 and also provides a well\-needed debug facility to the
1299 implementors/developers/maintainers of \fIMH\fR (the \fIMH\fR\-hacks).
1300 In the future, a user\-friendly \*(lqfront\-end\*(rq for \fImark\fR will
1301 probably be developed to give the \fIMH\fR user a way to take better
1302 advantage of the underlying facilities.
1303 .UH "Public and Private User\-Defined Sequences"
1305 There are two kinds of sequences: \fIpublic\fR sequences,
1306 and \fIprivate\fR sequences.
1307 \fIPublic\fR sequences of a folder are accessible to any \fIMH\fR user that
1308 can read that folder and are kept in the \&.mh\(rusequences file in the folder.
1309 \fIPrivate\fR sequences are accessible only to the \fIMH\fR user that defined
1310 those sequences and are kept in the user's \fIMH\fR context file.
1312 \fIpick\fR (and \fImark\fR\0) create \fIpublic\fR sequences
1313 if the folder for which the sequences are being defined is writable by the
1315 Otherwise, \fIprivate\fR sequences are created.
1316 This can be overridden with the `\-public' and `\-nopublic' switches.
1317 .UH "Sequence Negation"
1319 In addition to telling an \fIMH\fR command to use the messages in the sequence
1320 \*(lqseen\*(rq, as in
1325 it would be useful to be easily able to tell an \fIMH\fR command to use all
1326 messages \fIexcept\fR those in the sequence.
1327 One way of doing this would be to use \fImark\fR and define the sequence
1332 mark\0\-delete\0\-zero\0seen\0\-seq\0notseen
1335 owing to \fImark\fR\0's cryptic interpretation of `\-delete' and `\-zero',
1336 defines the sequence \*(lqnotseen\*(rq to be all messages not in the sequence
1339 anytime the sequence \*(lqseen\*(rq is changed,
1340 \*(lqnotseen\*(rq will have to be updated.
1341 Another way to achieve this is to define the entry
1342 \*(lqSequence\-Negation:\*(rq in the \&.mh\(ruprofile.
1346 Sequence\-Negation:\0not
1348 then anytime an \fIMH\fR command was given \*(lqnotseen\*(rq as a `msg' or
1350 it would substitute all messages that are not a member of the sequence
1355 refile\0notseen\0+new
1358 The value of the \*(lqSequence\-Negation:\*(rq entry in the profile can be
1361 experienced users of \fIMH\fR do not use a word,
1362 but rather a special character which their shell does not interpret
1363 (users of the \fICShell\fR use a single caret or circumflex (usually shift\-6),
1364 while users of the Bourne shell use an exclamation\-mark).
1365 This is because there is nothing to prevent a user of \fIMH\fR from defining a
1366 sequence with this string as its prefix,
1367 if the string is nothing by letters and digits.
1369 this could lead to confusing behavior
1370 if the \*(lqSequence\-Negation:\*(rq entry leads \fIMH\fR to believe that two
1371 sequences are opposites by virtue of their names differing by the prefix
1373 .UH "The Previous Sequence"
1375 Many times users find themselves issuing a series of commands on the same
1376 sequences of messages.
1377 If the user first defined these messages as a sequence,
1378 then considerable typing may be saved.
1379 If the user doesn't have this foresight,
1380 \fIMH\fR provides a handy way of having \fIMH\fR remember the `msgs' or
1381 `msg' argument last given to an \fIMH\fR command.
1382 If the entry \*(lqPrevious\-Sequence:\*(rq is defined in the
1384 then when the command finishes,
1385 it will define the sequence(s) named in the value of this entry as being
1386 exactly those messages that were specified.
1387 Hence, a profile entry of
1390 Previous\-Sequence:\0pseq
1392 directs any \fIMH\fR command that accepts a `msg' or `msgs' argument to
1393 define the sequence \*(lqpseq\*(rq as those messages when it finishes.
1394 More than one sequence name may be placed in this entry,
1395 separated with spaces.
1396 The one disadvantage of this approach
1397 is that the \fIMH\fR progams have to update the sequence information for
1398 the folder each time they run
1399 (although most programs read this information,
1400 usually only \fIpick\fR and \fImark\fR have to write this information out).
1401 .UH "The Unseen Sequence"
1403 Finally, some users like to distinguish between messages which have been
1404 previously seen by them.
1405 Both \fIinc\fR and \fIshow\fR honorthe profile entry
1406 \*(lqUnseen\-Sequence\*(rq to support this activity.
1407 Whenever \fIinc\fR places new messages in a folder,
1408 if the entry \*(lqUnseen\-Sequence\*(rq is defined in the \&.mh\(ruprofile,
1409 then when the command finishes,
1410 \fIinc\fR will add the new messages to the sequence(s) named in the value of
1412 Hence, a profile entry of
1415 Unseen\-Sequence:\0 unseen
1417 directs \fIinc\fR to add new messages to the sequence \*(lqunseen\*(rq.
1418 Unlike the behavior of the \*(lqPrevious\-Sequence\*(rq entry in the profile
1420 the sequence(s) will \fBnot\fR be zero'd.
1423 whenever \fIshow\fR (or \fInext\fR or \fIprev\fR\0) displays a message,
1424 they remove those messages from any sequences named by the
1425 \*(lqUnseen\-Sequence\*(rq entry in the profile.
1426 .uh "COMPOSITION OF MAIL"
1428 There are a number of interesting advanced facilities for the composition of
1431 .UH "The Draft Folder"
1433 The \fIcomp\fR, \fIdist\fR, \fIforw\fR, and \fIrepl\fR commands have two
1434 switches, `\-draftfolder\0+folder' and `\-draftmessage\0msg'.
1435 If `\-draftfolder\0+folder' is used,
1436 these commands are directed to construct a draft message in the indicated
1438 (The \*(lqDraft\-Folder:\*(rq profile entry may be used to declare a
1439 default draft folder for use with
1440 \fIcomp\fR, \fIdist\fR, \fIforw\fR, and \fIrepl\fR)
1441 If `\-draftmessage\0msg' is not used, it defaults to `new'
1442 (unless the user invokes \fIcomp\fR with `\-use',
1443 in which case the default is `cur').
1444 Hence, the user may have several message compositions in progress
1446 Now, all of the \fIMH\fR tools are available on each of the user's message
1448 (e.g., \fIshow\fR, \fIscan\fR, \fIpick\fR, and so on).
1449 If the folder does not exist,
1450 the user is asked if it should be created (just like with \fIrefile\fR\0).
1452 the last draft message the user was composing is known as `cur' in the
1456 the \fIsend\fR command has these switches as well.
1457 Hence, from the shell,
1458 the user can send off whatever drafts desired using the
1459 standard \fIMH\fR `msgs' convention with `\-draftmessage msgs'.
1460 If no `msgs' are given, it defaults to `cur'.
1463 all five programs have a `\-nodraftfolder' switch,
1464 which undoes the last occurrence of `\-draftfolder\0folder'
1465 (useful if the latter occurs in the user's \fIMH\fR profile).
1467 If the user does not give the `\-draftfolder\0+folder' switch,
1468 then all these commands act ``normally''.
1469 Note that the `\-draft' switch to \fIsend\fR and \fIshow\fR
1470 still refers to the file called `draft' in the user's \fIMH\fR
1472 In the interests of economy of expression,
1473 when using \fIcomp\fR or \fIsend\fR,
1474 the user needn't prefix the draft `msg' or `msgs' with
1476 Both of these commands accept a `file' or `files' argument,
1477 and they will, if given `\-draftfolder\0+folder' treat these arguments
1478 as `msg' or `msgs'.\**
1480 \** This may appear to be inconsistent, at first,
1481 but it saves a lot of typing.
1486 send -draftf +drafts first
1491 send -draftf +drafts -draftm first
1494 To make all this a bit more clear, here are some examples.
1495 Let's assume that the following entries are in the \fIMH\fR profile:
1499 Draft\-Folder: +drafts
1500 sendf: -draftfolder +drafts
1505 let's assume that the program \fIsendf\fR is a (symbolic) link in the user's
1506 \fB$HOME/bin/\fR directory to \fIsend\fR.
1507 Then, any of the commands
1518 constructs the message draft in the `draft' folder using the `new'
1521 they each define `cur' in this folder to be that message draft.
1522 If the user were to use the \fIquit\fR option at `What now?' level,
1524 if no other draft composition was done,
1525 the draft could be sent with simply
1531 if more editing was required,
1532 the draft could be edited with
1538 if other drafts had been composed in the meantime,
1539 so that this message draft was no longer known as `cur' in the `draft'
1541 then the user could \fIscan\fR the folder to see which message draft in the
1542 folder should be used for editing or sending.
1543 Clever users could even employ a back-quoted \fIpick\fR to do the work:
1546 comp -use `pick +drafts -to bug-mh`
1551 sendf `pick +drafts -to bug-mh`
1553 Note that in the \fIcomp\fR example,
1554 the output from \fIpick\fR must resolve to a single message draft
1555 (it makes no sense to talk about composing two or more drafts with one
1556 invocation of \fIcomp\fR\0).
1558 in the \fIsend\fR example,
1559 as many message drafts as desired can appear,
1560 since \fIsend\fR doesn't mind sending more than one draft at a time.
1562 Note that the argument `\-draftfolder\0+folder' is not
1563 included in the profile entry for \fIsend\fR,
1564 since when \fIcomp\fR, et. al., invoke \fIsend\fR directly,
1565 they supply \fIsend\fR with the UNIX pathname of the message draft,
1566 and \fBnot\fR a `draftmessage\0msg' argument.
1567 As far as \fIsend\fR is concerned,
1568 a \fIdraft folder\fR is not being used.
1570 It is important to realize that \fIMH\fR treats the draft folder like a standard
1571 \fIMH\fR folder in nearly all respects.
1572 There are two exceptions:
1574 under no circumstancs will the `\-draftfolder\0folder' switch cause the
1575 named folder to become the current folder.\**
1578 if the folder appeared in the context of a standard `+folder'
1579 argument to an \fIMH\fR program, as in
1584 it might become the current folder, depending on the context changes of the
1585 \fIMH\fR program in question.
1588 although conceptually \fIsend\fR deletes the `msgs' named in the draft
1590 it does not call `delete-prog' to perform the deletion.
1592 .UH "What Happens if the Draft Exists"
1594 When the \fIcomp\fR, \fIdist\fR, \fIforw\fR, and \fIrepl\fR commands are
1595 invoked and the draft you indicated already exists,
1596 these programs will prompt the user for a reponse directing the program's
1601 Draft ``/usr/src/uci/mh/mhbox/draft'' exists (xx bytes).
1605 The appropriate responses and their meanings are:
1607 deletes the draft and starts afresh;
1611 files the draft into a folder and starts afresh;
1614 leaves the draft intact and exits.
1615 In addition, if you specified `\-draftfolder\0folder' to the command,
1616 then one other response will be accepted:
1619 just as if `\-draftmessage\0new' had been given.
1620 Finally, the \fIcomp\fR command will accept one more response:
1623 just as if `\-use' had been given.
1625 .UH "The Push Option at What now? Level"
1627 The \fIpush\fR option to the \*(lqWhat now?\*(rq query
1628 in the \fIcomp\fR, \fIdist\fR, \fIforw\fR, and \fIrepl\fR commands,
1629 directs the command to \fIsend\fR the draft
1630 in a special detached fashion,
1631 with all normal output discarded.
1632 If \fIpush\fR is used and the draft can not be sent,
1633 then \fIMH\fR will send the user a message,
1634 indicating the name of the draft file,
1635 and an explanation of the failure.
1636 .\" Although using \fIpush\fR calls \fIsend\fR\0(1),
1637 .\" the \fIsend\fR command will consult the profile entry for \fIpush\fR.
1639 The user can also invoke \fIsend\fR from the shell with the `\-push'
1641 which makes \fIsend\fR act like it had been \fIpush\fR\0'd by one of the
1642 composition commands.
1643 .\" composition commands.\**
1645 .\" \** Note that in this case,
1646 .\" \fIsend\fR consults the profile entry for whatever name it was invoked as,
1647 .\" such as \fIsendf\fR.
1650 By using \fIpush\fR, the user can free the shell to do other things,
1651 because it appears to the shell that the \fIMH\fR command has finished.
1652 As a result the shell will immediately prompt for another command,
1653 despite the fact that the command is really still running.
1654 Note that if the user indicates that annotations are to be performed
1655 (with `\-annotate' to \fIdist\fR, \fIforw\fR, or \fIrepl\fR),
1656 the annotations will be performed after the message has been
1658 This action will appear to occur asynchronously.
1659 Obviously, if one of the messages that is to be annotated is
1660 removed before the draft has been successfully sent,
1661 then when \fIMH\fR tries to make the annotations,
1662 it won't be able to do so.
1663 In previous versions of \fIMH\fR,
1664 this resulted in an error message mysteriously appearing on the user's
1666 In \fImh.5\fR and later versions,
1667 in this special circumstance, no error will be generated.
1669 If send is \fIpush\fR\0'd,
1670 then the `\-forward' switch is examined if a failure notice is generated.
1672 then the draft is forwarded with the failure notice sent to the user.
1673 This allows rapid \fIburst\fR\0'ing of the failure notice to retrieve the
1676 .UH "Options at What now? Level"
1679 the message composition programs call a program called \fIwhatnow\fR before
1680 the initial draft composition.
1681 The \fIMH\fR user can specify any program for this.
1682 Following is some information about the default \*(lqWhat now?\*(rq level.
1683 More detailed information can be found in the \fIwhatnow\fR\0(1) manual entry.
1685 When using the \fIcomp\fR, \fIdist\fR, \fIforw\fR, and \fIrepl\fR commands at
1686 \*(lqWhat now?\*(rq level,
1687 the \fIedit\fR, \fIlist\fR, \fIheaders\fR, \fIrefile\fR,
1688 and (for the \fIdist\fR and \fIrepl\fR commands) the \fIdisplay\fR options
1689 will pass on any additional arguments given them to whatever program they
1692 In \fImh.1\fR (the original RAND \fIMH\fR\0)
1693 and \fImh.2\fR (the first UCI version of \fIMH\fR\0),
1694 \fIMH\fR used a complicated heuristic to determine if the draft should be
1695 deleted or preserved after an unsuccessful edit.
1697 \fIMH\fR was changed to preserve the draft always,
1698 since \fIcomp\fR, et. al.,
1699 could usually look at a draft, apply another set of heuristics,
1700 and decide if it was important or not.
1701 With the notion of a \fIdraft folder\fR,
1702 in which one by default gets a `new' message draft,
1703 the edit deletion/preservation algorithm was re-implemented,
1704 to keep the draft folder from being cluttered with aborted edits.
1707 note that by default,
1708 if the draft cannot be successfully sent,
1709 these commands return to \*(lqWhat now?\*(rq level.
1710 But, when \fIpush\fR is used, this does not happen (obviously).
1712 if these commands were expected to annotate any messages,
1713 this will have to be done by hand, later on, with the \fIanno\fR command.
1715 Finally, if the `\-delete' switch is not given to the \fIquit\fR option,
1716 then these commands will inform the user of the name of the unsent draft file.
1720 The \fIforw\fR command has the beginnings of a digestifying facility,
1721 with the `\-digest\ list', `\-issue\ number', and `\-volume\ number' switches.
1723 If \fIforw\fR is given \*(lqlist\*(rq to the `\-digest' switch
1724 as the name of the discussion group,
1725 and the `\-issue\ number' switch is not given,
1726 then \fIforw\fR looks for an entry in the user's \fIMH\fR context called
1727 \*(lq\fIdigest\fR\-issue\-list\*(rq and increments its value to use as the
1730 if the `\-volume\ number' switch is not given,
1731 then \fIforw\fR looks for \*(lq\fIdigest\fR\-volume\-list\*(rq
1732 (but does not increment its value) to use as the volume number.
1734 Having calculated the name of the digest and the volume and issue numbers,
1735 \fIforw\fR will now process the components file using the same format string
1736 mechanism used by \fIrepl\fR.
1737 The current `%'\-escapes are:
1740 .ta \w'escape 'u +\w'integer 'u
1741 \fIescape\fR \fItype\fR \fIsubstitution\fR
1742 digest string digest name
1743 msg integer issue number
1744 cur integer volume number
1748 In addition, to capture the current date,
1749 any of the escapes valid for \fIdp\fR\0(8) are also valid for \fIforw\fR.
1751 The default components file used by \fIforw\fR when in digest mode is:
1757 .so /opt/mh-6.8.5/lib/digestcomps
1762 Hence, when the `\-digest' switch is present,
1763 the first step taken by \fIforw\fR is to expand the format strings in the
1765 The next step is to compose the draft using
1766 the standard digest encapsulation algorithm
1767 (even putting an \*(lqEnd of list Digest\*(rq trailer in the draft).
1768 Once the draft is composed by \fIforw\fR,
1769 \fIforw\fR writes out the volume and issue profile entries for the digest,
1770 and then invokes the editor.
1772 Naturally, when composing the draft,
1773 \fIforw\fR will honor the `\-filter\ filterfile' switch,
1774 which is given to \fImhl\fR to filter each message being forwarded prior to
1775 encapsulation in the draft.
1776 A good filter file to use, which is called \fImhl.digest\fR, is:
1782 .so /opt/mh-6.8.5/lib/mhl.digest
1787 .uh "FOLDER HANDLING"
1789 There are two interesting facilities for manipulating folders:
1790 relative folder addressing,
1791 which allows a user to shorten the typing of long folder names;
1794 which permits a user to keep a stack of current folders.
1796 .UH "Relative Folder Addressing"
1798 By default, when `+folder' is given,
1799 and the folder name is not absolute
1800 (does not start with \fB/\fR, \fB\&./\fR, or \fB\&.\&./\fR),
1801 then the UNIX pathname of the folder is interpreted relative to the user's
1803 Although this mechanism works fine for top\-level folders and their immediate
1805 once the depth of the sub\-folder tree grows, it becomes rather unwieldly:
1808 scan\0+mh/mh.4/draft/flames
1811 \fIMH\fR can't do anything if the current folder was \*(lq+inbox\*(rq,
1812 but if the current folder was, say, \*(lq+mh/mh.4/draft\*(rq,
1813 \fIMH\fR has a short\-hand notation to reference a sub\-folder of the
1815 Using the `@folder' notation,
1816 the \fIMH\fR user can direct any \fIMH\fR program which expects a `+folder'
1817 argument to look for the folder relative to the current folder instead of the
1818 user's \fIMH\fR directory.
1819 Hence, if the current folder \fIwas\fR \*(lq+mh/mh.4/draft\*(rq,
1825 would do the trick handily.
1826 In addition, if the current folder \fIwas\fR \*(lq+mh/mh.4/draft\*(rq,
1831 would scan the folder \*(lq+mh/mh.4/pick\*(rq,
1832 since, in the UNIX fashion,
1833 it references the folder \*(lqpick\*(rq which is a sub\-folder of
1834 the folder that is the parent of the current folder.
1835 Since most advanced \fIMH\fR users seem to exhibit a large degree of locality
1836 in referencing folders when they process mail,
1837 this convention should receive a wide range of uses.
1839 .UH "The Folder\-Stack"
1841 The \fIfolder\-stack\fR mechanism in \fIMH\fR gives the \fIMH\fR user a
1842 facility similar to the \fICShell\fR\0's directory\-stack.
1846 folder\0\-push\0+foo
1848 makes \*(lqfoo\*(rq the current folder,
1849 saving the folder that was previously the current folder on the
1850 \fIfolder\-stack\fR.
1856 takes the top of the \fIfolder\-stack\fR and makes it the current folder.
1857 Each of these switches lists the \fIfolder\-stack\fR when they execute.
1858 It is simple to write a \fIpushf\fR command as a shell script.
1862 exec\0folder\0\-push\0$@
1864 Probably a better way is to link \fIfolder\fR to the $HOME/bin/ directory under
1865 the name of \fIpushf\fR and then add the entry
1870 to the \&.mh\(ruprofile.
1872 The manual page for \fIfolder\fR discusses the analogy between the
1873 \fICShell\fR directory stack commands and the switches in \fIfolder\fR which
1874 manipulate the \fIfolder\-stack\fR.
1875 The \fIfolder\fR command uses the context entry `Folder\-Stack:' to keep
1876 track of the folders in the user's stack of folders.
1878 \" On to the Appendices
1886 .de $c \" Major Heading printer
1891 .b "\\s12\\$1\\s0" \" 12 Point Bold Header
1893 \ \ \ \\n(ch.\\ \\ \\$2
1895 .sp 45p \" 45 points or about 1/2 inch
1899 .$c "COMMAND SUMMARY" "Command Summary"
1908 .$c "MESSAGE NAME BNF" "Message Name BNF"
1912 .ta \w'user-defined-sequence 'u +\w':= 'u +\w'user-defined-sequence 'u
1919 user-defined-sequence
1924 msg-name := \*(lqfirst\*(rq |
1931 msg-range := msg\*(lq\-\*(rqmsg |
1934 msg-sequence := msg\*(lq:\*(rqsigned-number
1936 signed-number := \*(lq+\*(rq<number> |
1937 \*(lq\-\*(rq<number> |
1940 user-defined-sequence := <alpha> |
1941 <alpha><alphanumeric>*
1946 Where <number> is a decimal number greater than zero.
1948 Msg-range specifies all of the messages in the given range
1949 and must not be empty.
1951 Msg-sequence specifies up to <number> of messages, beginning
1952 with \*(lqmsg\*(rq (in the case of first, cur, next, or <number>),
1953 or ending with \*(lqmsg\*(rq (in the case of prev or last).
1954 +<number> forces \*(lqstarting with msg\*(rq, and \-<number> forces
1955 \*(lqending with number\*(rq.
1956 In all cases, \*(lqmsg\*(rq must exist.
1958 User\-defined sequences are defined and manipulated with the \fIpick\fR
1959 and \fImark\fR commands.
1963 .b \\s12REFERENCES\\s0
1971 1. Crocker, D. H., J. J. Vittal, K. T. Pogran, and D. A. Henderson, Jr.,
1972 \*(lqStandard for the Format of ARPA Network Text Messages,\*(rq
1977 2. Thompson, K., and D. M. Ritchie, \*(lqThe UNIX Time-sharing System,\*(rq
1978 \fICommunications of the ACM\fR, Vol. 17, July 1974, pp. 365-375.
1981 3. McCauley, E. J., and P. J. Drongowski, \*(lqKSOS\-The Design of a Secure
1982 Operating System,\*(rq \fIAFIPS Conference Proceedings\fR,
1983 National Computer Conference,
1984 Vol. 48, 1979, pp. 345-353.
1987 4. Crocker, David H., \fIFramework and Functions of the \*(lqMS\*(rq Personal
1988 Message System\fR, The RAND Corporation, R-2134-ARPA, December 1977.
1991 5. Thompson, K., and D. M. Ritchie, \fIUNIX Programmer's Manual\fR, 6th ed.,
1992 Western Electric Company, May 1975 (available only to UNIX licensees).
1996 \*(lqStandard for the Format of ARPA Internet Text Messages,\*(rq
2001 .b "\\s12\\$1\\s0" \" 12 Point Bold Header
2014 Although the \fIMH\fR system was originally developed by the RAND Corporation,
2015 and is now in the public domain,
2016 the RAND Corporation assumes no responsibility for \fIMH\fR
2017 or this particular version of \fIMH\fR.
2020 the Regents of the University of California issue the following
2021 \fBdisclaimer\fR in regard to the UCI version of \fIMH\fR:
2024 \*(lqAlthough each program has been tested by its contributor,
2025 no warranty, express or implied,
2026 is made by the contributor or the University of California,
2027 as to the accuracy and functioning of the program
2028 and related program material,
2029 nor shall the fact of distribution constitute any such warranty,
2030 and no responsibility is assumed by the contributor
2031 or the University of California in connection herewith.\*(rq
2034 This version of \fIMH\fR is in the public domain,
2036 there are no real restrictions on its use.
2037 The \fIMH\fR source code and documentation have no licensing restrictions
2040 the authors ask only that you provide appropriate credit to the RAND
2041 Corporation and the University of California for having developed the software.
2043 \fIMH\fR is a software package that is supported neither by the RAND
2044 Corporation nor the University of California.
2046 since we do use the software ourselves and plan to continue using
2047 (and improving) \fIMH\fR,
2048 bug reports and their associated fixes should be reported back to us so that
2049 we may include them in future releases.
2050 The current computer mailbox for \fIMH\fR is \fBBug\-MH@ICS.UCI.EDU\fR
2051 (in the ARPA Internet),
2052 and \fB...!ucbvax!ucivax!bug\-mh\fR (UUCP).
2054 there are two Internet discussion groups, \fBMH\-Users@ICS.UCI.EDU\fR
2055 and \fBMH\-Workers@ICS.UCI.EDU\fR. \fBMH\-Workers\fP is for people
2056 discussing code changes to \fIMH\fP. \fBMH-Users\fP is for general
2057 discussion about how to use \fIMH\fP.
2058 \fBMH\-Users\fR is bi-directionally
2059 gatewayed into USENET as \fBcomp.mail.mh\fR.
2062 Since you probably already have \fIMH\fP,
2063 you may not need to read this unless you suspect you have an old version.
2064 On the Internet, you may retrieve the lastest release from one of:
2068 ftp://ftp.ics.uci.edu/pub/mh/mh-6.8.tar.Z
2069 ftp://ftp.uu.uunet/networking/mail/mh/mh-6.8.tar.Z
2070 http://wuarchive.wustl.edu/packages/mail/mh/mh-6.8.tar.Z
2075 This is a tar image after being run through the compress program
2076 (approximately 2Mb). There is also an \fIMH\fP World Wide Web
2077 Home Page at \*(lqhttp://www.ics.uci.edu/\~mh\*(rq
2078 which tells what the current release of \fIMH\fP
2079 is, and how to get updates.
2081 You may also find MH on
2082 various other hosts; to make sure you get the latest version and
2083 don't waste your time re-fixing bugs, it's best to get it from
2084 either ftp.ics.uci.edu or a site which mirrors ftp.ics.uci.edu.
2086 Alternatively, you can send $75 US to the address below.
2087 This covers the cost of a 6250 BPI 9-track magtape,
2088 handling, and shipping. In addition, you'll get a
2089 laser-printed hard-copy of the entire MH documentation set. Be
2090 sure to include your USPS address with your check. Checks
2091 must be drawn on U.S\&. funds and should be made payable to:
2094 Regents of the University of California
2096 The distribution address is:
2100 Attn: MH distribution
2101 Office of Academic Computing
2102 University of California, Irvine
2103 Irvine, CA 92717-2225
2109 If you just want the hard-copies of the documentation, you
2110 still have to pay the $75. The tar image has the documentation
2111 source (the manual is in roff format, but the rest are in TeX
2112 format). Postscript formatted versions of the TeX papers are
2113 available, as are crude tty-conversions of those papers.
2116 This document describes the RAND \fIMH\fR Message Handling System.
2117 Its primary purpose is to serve as a user's manual.
2118 It has been heavily based on a previous version of the manual,
2119 prepared by Bruce Borden, Stockton Gaines, and Norman Shapiro.
2121 \fIMH\fR is a particularly novel system,
2122 and thus it is often more prone to change than other pieces of production
2124 As such, some specific points in this manual may not be correct in the
2126 In all cases, the on\-line sections of this manual,
2127 available through the UNIX\** \fIman\fR command,
2128 should present the most current information.
2130 \** UNIX is a trademark of AT&T Bell Laboratories.
2133 When reading this document as a user's manual,
2134 certain sections are more interesting than others.
2135 The Preface and Summary are not particularly interesting to those
2136 interested in learning \fIMH\fR.
2137 The Introduction is slightly more interesting,
2138 as it touches upon the organization of the remainder of this document.
2139 The most useful sections are the Overview, Tutorial, and Detailed
2141 The Overview should be read by all \fIMH\fR users, regardless of their
2142 expertise (beginning, novice, advanced, or hacker).
2143 The Tutorial should be read by all beginning and novice \fIMH\fR users,
2144 as it presents a nice description of the \fIMH\fR system.
2145 The Detailed Description should be read by the day\-to\-day user of \fIMH\fR,
2146 as it spells out all of the realities of the \fIMH\fR system.
2147 The Advanced Features section discusses some powerful \fIMH\fR capabilities for
2149 Appendix A is particularly useful for novices,
2150 as it summarizes the invocation syntax of all the \fIMH\fR commands.
2152 There are also several other documents which may be useful to you:
2153 \fIThe RAND MH Message Handling System: Tutorial\fR,
2154 which is a tutorial for \fIMH\fR;
2155 \fIThe RAND MH Message Handling System: The UCI BBoards Facility\fR,
2156 which describes the BBoards handling under \fIMH\fR;
2157 \fIMH.5: How to process 200 messages a day and still get some real work
2159 which was presented at the 1985 Summer Usenix Conference and
2160 Exhibition in Portland, Oregon;
2161 \fIMH: A Multifarious User Agent\fR,
2162 which has been accepted for publication by Computer Networks;
2163 \fIMZnet: Mail Service for Personal Micro\-Computer Systems\fR,
2164 which was presented at the First International Symposium on Computer Message
2165 Systems in Nottingham, U.K.;
2167 \fIDesign of the TTI Prototype Trusted Mail Agent\fR,
2168 which describes a proprietary \*(lqtrusted\*(rq mail system built on \fIMH\fR.
2169 There are also documents, mostly specific to U.C.\0Irvine which you may find
2171 \fIMH for Beginners\fR, and \fIMH for MM Users\fR.
2172 All of these documents exist in the \fImh.6\fR distribution sent to your
2174 There's also a document,
2175 \fIChanges to the RAND MH Message Handling System: MH.6\fR,
2176 which describes user\-visible changes made to \fIMH\fR since the last major
2179 This manual is very large, as it describes a large, powerful system in
2181 The important thing to remember is:
2184 .b "\s+4DON'T PANIC\s0\**"
2186 As explained in the tutorial, you really need to know only 5 commands to
2187 handle most of your mail.
2189 \** Note the large, \fIfriendly\fR letters.
2192 Very advanced users may wish to consult
2193 \fIThe RAND MH Message Handling System: Administrator's Guide\fR,
2194 which is also present in the \fImh.6\fR distribution sent to your site.
2197 The \fIMH\fR system described herein is based on the original RAND \fIMH\fR
2199 It has been extensively developed (perhaps too much so) by Marshall T. Rose and
2200 John L. Romine at the University of California, Irvine.
2201 Einar A. Stefferud, Jerry N. Sweet, and Terry P. Domae provided numerous
2202 suggestions to improve the UCI version of \fIMH\fR.
2204 a large number of people have helped \fIMH\fR along.
2205 The list of ``\fIMH\fR immortals'' is too long to list here.
2206 However, Van Jacobson deserves a special acknowledgement for his tireless
2207 work in improving the performance of \fIMH\fR.
2208 Some programs have been speeded-up by a factor of 10 or 20.
2209 All of users of \fIMH\fR, everywhere, owe a special thanks to Van.
2210 For this release, numerous \fIMH\-Workers\fP sent in fixes and other
2211 changes. A handful of courageous \fIMH\-Workers\fP volunteered
2212 to beta\-test these changes; their help is particularly appreciated.
2214 This manual is based on the original \fIMH\fR manual written at RAND by
2215 Bruce Borden, Stockton Gaines, and Norman Shapiro.
2218 This report describes a system for dealing with messages transmitted on a
2219 computer. Such messages might originate with other users of the same
2220 computer or might come from an outside source through a network to which the user's
2221 computer is connected. Such computer-based message systems are
2222 becoming increasingly widely used, both within and outside the Department
2225 The message handling system \fIMH\fR was developed for two reasons.
2226 One was to investigate some
2227 research ideas concerning how a message system might take advantage of
2228 the architecture of the UNIX time-sharing operating system for
2229 Digital Equipment Corporation PDP-11 and VAX computers, and the special
2230 features of UNIX's command-level interface with the user (the
2231 \*(lqshell\*(rq). The other reason was to provide a better and more
2232 adaptable base than that of conventional designs
2233 on which to build a command and control message system.
2234 The effort has succeeded in both
2235 regards, although this report mainly describes the message system itself
2236 and how it fits in with UNIX.
2238 The present report should be of interest to three groups of readers. First,
2239 it is a complete reference manual for the users of \fIMH\fR.
2240 Second, it should be
2241 of interest to those who have a general knowledge of computer-based
2242 message systems, both in civilian and military applications. Finally,
2243 it should be of interest to those who build large subsystems that
2244 interface with users, since it illustrates a new approach to such
2247 The original \fIMH\fR system was developed by Bruce Borden,
2248 using an approach suggested by Stockton Gaines and Norman Shapiro.
2249 Valuable assistance was provided by Phyllis Kantar in the later
2250 stages of the system's implementation.
2252 contributed to the ideas included in this system, particularly
2253 Robert Anderson and David Crocker.
2254 In addition, valuable experience
2255 in message systems, and a valuable source of ideas, was available
2256 to us in the form of a previous message system for UNIX called
2257 MS, designed at RAND by David Crocker.
2259 This report was originally prepared as part of the RAND project entitled
2260 \*(lqData Automation Research\*(rq, sponsored by Project AIR FORCE.
2263 Electronic communication of text messages is becoming
2264 commonplace. Computer-based message systems\-software
2265 packages that provide tools for dealing with messages\-are used in many
2266 contexts. In particular, message systems are becoming
2267 increasingly important in command and control and intelligence
2270 This report describes a message handling system called \fIMH\fR.
2271 This system provides the user
2272 with tools to compose, send, receive, store, retrieve, forward, and
2273 reply to messages. \fIMH\fR has been built on the UNIX time-sharing system,
2274 a popular operating system developed for the DEC PDP-11 and VAX classes of
2277 A complete description of \fIMH\fR is given for users of
2278 the system. For those who do not intend to use the system, this description
2279 gives a general idea of what a message system is like. The system involves
2280 some new ideas about how large subsystems can be constructed.
2282 The interesting and unusual features of \fIMH\fR include the
2283 following: The user command interface to \fIMH\fR is the UNIX \*(lqshell\*(rq
2284 (the standard UNIX command interpreter). Each separable
2285 component of message handling, such as message composition or
2286 message display, is a separate command. Each program is driven from
2287 and updates a private user environment, which is stored as a file
2288 between program invocations. This private environment also contains
2289 information to \*(lqcustom tailor\*(rq \fIMH\fR to the individual's tastes.
2290 \fIMH\fR stores each message as a separate file under UNIX, and it utilizes the
2291 tree-structured UNIX file system to organize groups of files within
2292 separate directories or \*(lqfolders\*(rq. All of the UNIX facilities
2293 for dealing with files and directories, such as
2294 renaming, copying, deleting, cataloging, off-line printing, etc., are
2295 applicable to messages and directories of messages (folders). Thus,
2296 important capabilities needed in a message system are available in \fIMH\fR
2297 without the need (often seen in other message systems) for code that
2298 duplicates the facilities of the supporting operating system.
2299 It also allows users familiar with the shell to use \fIMH\fR with minimal
2305 .b \\s12CONTENTS\\s0
2310 .\" And now the COVER sheet
2336 Based on the original manual by
2337 Borden, Gaines, and Shapiro