9 date 92.10.28.16.53.03; author jromine; state Exp;
14 date 92.10.27.20.21.36; author jromine; state Exp;
19 date 92.10.26.16.36.30; author jromine; state Exp;
24 date 92.07.02.15.51.22; author jromine; state Exp;
29 date 92.02.15.00.08.56; author jromine; state Exp;
34 date 92.02.12.19.10.01; author jromine; state Exp;
39 date 92.02.12.19.08.15; author jromine; state Exp;
44 date 92.02.12.05.59.38; author jromine; state Exp;
49 date 92.02.12.04.24.50; author jromine; state Exp;
54 date 92.02.12.02.49.43; author jromine; state Exp;
59 date 92.02.12.02.31.09; author jromine; state Exp;
64 date 92.02.12.00.23.07; author jromine; state Exp;
69 date 92.02.11.23.48.28; author jromine; state Exp;
74 date 92.02.11.23.15.24; author jromine; state Exp;
79 date 92.02.11.21.45.43; author jromine; state Exp;
94 .\" @@(#)$Id: slocal.rf,v 1.14 1992/10/27 20:21:36 jromine Exp jromine $
97 slocal \- special local mail delivery
99 @@(MHETCPATH)/slocal \%[address\ info\ sender]
109 .\" \%[\-home\ homedir]
111 \%[\-maildelivery\ deliveryfile]
112 \%[\-verbose] \%[\-noverbose]
117 \fISlocal\fP is a program designed to allow you to have
118 your inbound mail processed according to a complex
119 set of selection criteria.
120 You do not normally invoke \fIslocal\fP yourself,
121 rather \fIslocal\fP is invoked on your behalf by your system's
122 Message Transfer Agent.
124 The message selection
125 criteria used by \fIslocal\fP
126 is specified in the file \fI\&.maildelivery\fP
127 in the user's home directory. The format of this file
130 The message delivery address and message sender are
131 determined from the Message Transfer Agent
132 envelope information, if possible. Under \fISendMail\fP,
133 the sender will obtained from the UUCP \*(lqFrom\ \*(rq
134 line, if present. The user may override these values
135 with command line arguments, or arguments to
136 the `\-addr' and `\-sender' switches.
138 The message is normally read from the standard input.
139 The `\-file' switch sets the name of the file from which
140 the message should be read, instead of reading stdin.
141 The `\-user' switch tells \fIslocal\fP
142 the name of the user for whom it is delivering mail.
143 The `\-mailbox' switch tells \fIslocal\fP the name
144 of the user's maildrop file.
146 The `\-info' switch may be used to pass an arbitrary
147 argument to sub-processes which \fIslocal\fP may
148 invoke on your behalf.
149 The `\-verbose' switch causes \fIslocal\fP
150 to give information on stdout about its progress.
151 The `\-debug' switch produces more verbose debugging output on stderr.
153 .Uh "Message Transfer Agents"
154 If your MTA is \fISendMail\fP,
155 you should include the line
159 \*(lq|\ @@(MHETCPATH)/slocal\ \-user\ username\*(rq
163 in your \&.forward file in your home directory.
164 This will cause \fISendMail\fP to invoke \fIslocal\fP on your behalf.
166 If your MTA is \fIMMDF-I\fP,
167 you should (symbolically) link @@(MHETCPATH)/slocal to the file
168 bin/rcvmail in your home directory.
169 This will cause \fIMMDF-I\fP to invoke \fIslocal\fP on your behalf
170 with the correct \*(lq\fIaddress\ info\ sender\fP\*(rq arguments.
172 If your MTA is \fIMMDF-II\fP,
173 then you should not use \fIslocal\fP.
174 An equivalent functionality is already provided by \fIMMDF-II\fP;
175 see maildelivery(5) for details.
177 .Uh "The Maildelivery File"
179 The \fI\&.maildelivery\fR file
180 controls how local delivery is performed.
181 Each line of this file
182 consists of five fields, separated by white-space or comma.
183 Since double-quotes are honored,
184 these characters may be included in a single argument by enclosing the
185 entire argument in double-quotes.
186 A double-quote can be included by preceding it with a backslash.
187 Lines beginning with `#' are ignored.
188 The format of each line in the \fI\&.maildelivery\fR file is:
191 \fBheader pattern action result string\fR
197 The name of a header field that is to be searched for a pattern.
198 This is any field in the headers of the message that might be present.
199 The following special fields are also defined:
204 \fIsource\fR the out-of-band sender information
206 \fIaddr\fR the address that was used to cause delivery to the recipient
208 \fIdefault\fR this matches \fIonly\fR if the message hasn't been delivered yet
210 \fI*\fR this always matches
217 of characters to match in the specified header field.
218 Matching is case-insensitive, but does not use regular expressions.
223 The action to take to deliver the message:
228 \fIdestroy\fR This action always succeeds.
231 \fIfile\fR or > Append
232 the message to the file named by \fBstring\fR.
233 The message is appended to the file in the maildrop
234 format which is used by your message transport system.
235 If the message can be appended to the file,
236 then this action succeeds.
237 When writing to the file,
238 a \*(lqDelivery\-Date:\ date\*(rq header is added
239 which indicates the date and time that message was appended to the file.
244 but always appends the message using the format used by \fIpackf\fR
245 (the MMDF mailbox format).
249 the message as the standard input to the command named by \fBstring\fR,
250 using the Bourne shell \fIsh\fR(1) to interpret the string.
251 Prior to giving the string to the shell,
252 it is expanded with the following built-in variables:
257 $(sender) the out-of-band sender information
259 $(address) the address that was used to cause delivery to the recipient
261 $(size) the size of the message in bytes
263 $(reply\-to) either the \*(lqReply\-To:\*(rq or \*(lqFrom:\*(rq field
266 $(info) the out-of-band information specified
271 \fI<caret>\fR Similar to \fIpipe\fR,
272 but executes the command directly,
273 after built-in variable expansion,
274 without assistance from the shell.
275 This action can be used to avoid quoting special characters
276 which your shell might interpret.
282 Indicates how the action should be performed:
287 \fIA\fR Perform the action.
288 If the action succeeds, then the message is considered delivered.
291 \fIR\fR Perform the action.
292 Regardless of the outcome of the action,
293 the message is not considered delivered.
297 the action only if the message has not been delivered.
298 If the action succeeds, then the message is considered delivered.
302 the action only if the message has not been delivered
303 and the previous action succeeded.
304 If this action succeeds, then the message is considered delivered.
308 To summarize, here's an example:
312 .ta \w'default 'u +\w'mh-workersxx 'uC +\w'destroy 'uC +\w'result 'u
313 #\fIfield\fR \fIpattern\fR \fIaction\fR \fIresult\fR \fIstring\fR
314 # lines starting with a '#' are ignored, as are blank lines
316 # file mail with mmdf2 in the \*(lqTo:\*(rq line into file mmdf2.log
317 \fITo mmdf2 file A mmdf2.log\fP
318 # Messages from mmdf pipe to the program err-message-archive
319 \fIFrom mmdf pipe A /bin/err-message-archive\fP
320 # Anything with the \*(lqSender:\*(rq address \*(lqmh-workers\*(rq
321 # file in mh.log if not filed already
322 \fISender mh-workers file ? mh.log\fP
323 # \*(lqTo:\*(rq unix \- put in file unix-news
324 \fITo Unix > A unix-news\fP
325 .\" # if the address is jpo=mmdf \- pipe into mmdf-redist
326 .\" \fIaddr jpo=mmdf | A mmdf-redist\fP
327 # if the address is jpo=ack \- send an acknowledgement copy back
328 \fIaddr jpo=ack \fP|\fI R \*(lq/bin/resend\0\-r\0$(reply-to)\*(rq\fP
329 # anything from steve \- destroy!
330 \fIFrom steve destroy A \-\fP
331 # anything not matched yet \- put into mailbox
332 \fIdefault \- > ? mailbox\fP
334 \fI* \- \fP|\fI R /mh/lib/rcvtty\fP
339 The file is always read completely,
340 so that several matches can be made and several actions can be taken.
341 The \fI\&.maildelivery\fR file must be owned either by the user or by root,
342 and must be writable only by the owner.
343 If the \fI\&.maildelivery\fR file cannot be found,
344 or does not perform an action which delivers the message,
345 then the file @@(MHETCPATH)/maildelivery is read according to the same rules.
346 This file must be owned by the root and must be writable only by the root.
347 If this file cannot be found
348 or does not perform an action which delivers the message,
349 then standard delivery to the user's maildrop is performed.
351 .Uh "Sub-process environment"
352 When a process is invoked, its environment is:
353 the user/group-ids are set to recipient's ids;
354 the working directory is the recipient's home directory;
356 the process has no /dev/tty;
357 the standard input is set to the message;
358 the standard output and diagnostic output are set to /dev/null;
359 all other file-descriptors are closed;
360 the envariables \fB$USER\fR, \fB$HOME\fR, \fB$SHELL\fR are set
362 and no other envariables exist.
364 The process is given a certain amount of time to execute.
365 If the process does not exit within this limit,
366 the process will be terminated with extreme prejudice.
367 The amount of time is calculated as ((size x 60) + 300) seconds,
368 where size is the number of bytes in the message.
370 The exit status of the process is consulted in determining the success of the
372 An exit status of zero means that the action succeeded.
373 Any other exit status (or abnormal termination) means that the action failed.
375 In order to avoid any time limitations,
376 you might implement a process that began by \fIforking\fR.
377 The parent would return the appropriate value immediately,
378 and the child could continue on,
379 doing whatever it wanted for as long as it wanted.
380 This approach is somewhat risky if the parent is going to return an
382 If the parent is going to return a non-zero exit status,
383 then this approach can lead to quicker delivery into your maildrop.
386 .Uh "Duplicate Message Suppression"
387 \fIslocal\fR is able to detect and supress duplicate messages.
389 create two empty files in your $HOME directory:
390 \&.maildelivery.pag and \&.maildelivery.dir.
391 These are ndbm files which are used to store the Message-IDs of
395 ^@@(MHETCPATH)/mtstailor~^MH tailor file
396 ^$HOME/\&.maildelivery~^The file controlling local delivery
397 ^@@(MHETCPATH)/maildelivery~^Rather than the standard file
398 ^@@(MHDROPLOC)~^The default maildrop
400 rcvstore(1), mhook(1), mh\-format(5)
407 `\-maildelivery \&.maildelivery'
409 `\-mailbox @@(MHDROPLOC)'
411 `\-file' defaults to stdin
413 `\-user' defaults to the current user
418 For compatibility with older versions of \fIMH\fR,
419 if \fIslocal\fR can't find the user's \fI\&.maildelivery\fR file,
420 it will attempt to execute an old-style rcvmail hook in the user's $HOME
423 it will first attempt to execute
426 \&.mh\(rureceive file maildrop directory user
428 failing that it will attempt to execute
431 $HOME/bin/rcvmail user file sender
433 before giving up and writing to the user's maildrop.
436 whenever a hook or process is invoked,
437 file-descriptor three (3) is set to the message in addition to the standard
441 \fISlocal\fP is designed to be backward-compatible with the
442 \fImaildelivery\fP facility provided by \fIMMDF-II\fP.
443 Thus, the \fI\&.maildelivery\fP file syntax is limited,
444 as is the functionality of \fIslocal\fP.
446 In addition to an exit status of zero,
447 the \fIMMDF\fR values \fIRP_MOK\fR (32) and \fIRP_OK\fR (9)
448 mean that the message has been fully delivered.
449 Any other non-zero exit status,
450 including abnormal termination,
451 is interpreted as the \fIMMDF\fR value \fIRP_MECH\fR (200),
452 which means \*(lquse an alternate route\*(rq
453 (deliver the message to the maildrop).
455 Only two return codes are meaningful, others should be.
457 \fISlocal\fP is designed to be
458 backwards-compatible with the \fImaildelivery\fP functionality provided
461 Versions of \fIMMDF\fR with the \fImaildelivery\fR mechanism aren't
462 entirely backwards-compatible with earlier versions of \fIMMDF\fP.
463 If you have an \fIMMDF-I\fP old-style hook,
464 the best you can do is to have a one-line
465 \fI\&.maildelivery\fR file:
468 default \- pipe A \*(lqbin/rcvmail $(address) $(info) $(sender)\*(rq
475 @note MMDF-II compatibility goal
480 .\" @@(#)$Id: slocal.rf,v 1.13 1992/10/26 16:36:30 jromine Exp jromine $
487 @document MSGID option
492 .\" @@(#)$Id: slocal.rf,v 1.12 1992/07/02 15:51:22 jromine Exp jromine $
499 @document troubles with "pipe" & special characters
504 .\" @@(#)$Id: slocal.rf,v 1.11 1992/02/15 00:08:56 jromine Exp jromine $
512 @changes from Stephen Gildea
517 .\" @@(#)$Id: slocal.rf,v 1.10 1992/02/12 19:10:01 jromine Exp jromine $
529 .\" @@(#)$Id: slocal.rf,v 1.9 1992/02/12 19:08:15 jromine Exp jromine $
532 consists of five fields, separated by white\-space or comma.
533 Since double\-quotes are honored,
536 entire argument in double\-quotes.
537 A double\-quote can be included by preceeding it with a backslash.
540 it is expanded with the following built\-in variables:
543 after built\-in variable expansion,
546 If the \fI\&.maildelivery\fR file can not be found,
549 If this file can not be found
552 the working directory is the recipient's directory;
555 all other file\-descriptors are closed;
558 If the parent is going to return a non\-zero exit status,
561 it will attempt to execute an old\-style rcvmail hook in the user's $HOME
564 file\-descriptor three (3) is set to the message in addition to the standard
567 All other non\-zero exit status,
570 entirely backwards\-compatible with earlier versions of \fIMMDF\fP.
571 If you have an \fIMMDF-I\fP old\-style hook,
572 the best you can do is to have a one\-line
583 .\" @@(#)$Id: slocal.rf,v 1.8 1992/02/12 05:59:38 jromine Exp jromine $
586 You do not normallynormally invoke \fIslocal\fP yourself,
592 @enclose cmd in quotes
597 .\" @@(#)$Id: slocal.rf,v 1.7 1992/02/12 04:24:50 jromine Exp jromine $
600 You do \fBNOT\fR invoke \fIslocal\fP yourself,
603 $(info) miscellaneous out-of-band information as specified
609 .ta \w'defaultxxx 'u +\w'mh-workers 'uC +\w'action'uC +\w'result'u
615 The file is always read completely,
616 so that several matches can be made and several actions can be taken.
617 The \fI\&.maildelivery\fR file must be owned either by the user or by root,
618 and must be writable only by the owner.
619 If the \fI\&.maildelivery\fR file can not be found,
620 or does not perform an action which delivers the message,
621 then the file @@(MHETCPATH)/maildelivery is read according to the same rules.
622 This file must be owned by the root and must be writable only by the root.
623 If this file can not be found
624 or does not perform an action which delivers the message,
625 then standard delivery to the user's maildrop is performed.
634 .\" For compatibility with older versions of \fIMH\fR,
635 .\" if \fIslocal\fR can't find the user's \fI\&.maildelivery\fR file,
636 .\" it will attempt to execute an old\-style rcvmail hook in the user's $HOME
639 .\" it will first attempt to execute
642 .\" \&.mh\(rureceive file maildrop directory user
644 .\" failing that it will attempt to execute
647 .\" $HOME/bin/rcvmail user file sender
649 .\" before giving up and writing to the user's maildrop.
652 .\" whenever a hook or process is invoked,
653 .\" file\-descriptor three (3) is set to the message in addition to the standard
672 .\" @@(#)$Id: slocal.rf,v 1.6 1992/02/12 02:49:43 jromine Exp jromine $
675 |\ @@(MHETCPATH)/slocal\ \-user\ username
686 .\" @@(#)$Id: slocal.rf,v 1.5 1992/02/12 02:31:09 jromine Exp jromine $
689 the sender will obtained from the UUCP \*(lqFrom \*(rq
692 to give information on stdout about the its progress.
695 with the \*(lqaddress\ info\ sender\*(rq arguments.
706 .\" @@(#)$Id: slocal.rf,v 1.4 1992/02/12 00:23:07 jromine Exp $
710 \fISlocal\fP is a program designed to allow inbound
711 mail to be processed according to a set of selection
713 You do \fBNOT\fR invoke the hook yourself,
714 rather the hook is invoked on your behalf by the
717 criteria is specified in the file \fI\&.maildelivery\fP
720 The delivery address and message sender are
724 The `\-debug' switch produces verbose debugging output on stderr.
727 This will cause \fIMMDF-I\fP to invoke \fIslocal\fP on your behalf.
730 An equivalent functionality is already provide by \fIMMDF-II\fP;
733 The \fI\&.maildelivery\fR file,
734 which is an ordinary ASCII file,
738 \fBfield pattern action result string\fR
745 name of a header field that is to be searched for a pattern.
748 \fIsource\fR the out\-of\-band sender information
751 of characters to match in the specified field.
752 Matching is case\-insensitive but not does not use regular expressions.
755 using the Bourne shell \fIsh\fR\0(1) to interpret the string.
758 $(sender) the return address for the message
761 $(info) miscellaneous out\-of\-band information
767 Arguments in the \fI\&.maildelivery\fR file are separated by white\-space or
769 Since double\-quotes are honored,
770 these characters may be included in a single argument by enclosing the
771 entire argument in double\-quotes.
772 A double\-quote can be included by preceeding it with a backslash.
779 .ta \w'default 'u +\w'mh-workersxxx 'uR +\w'action'uC +\w'result'u
782 \fIaddr jpo=ack | R \*(lq/bin/resend\0\-r\0$(reply-to)\*(rq\fP
785 \fI* \- | R /mh/lib/rcvtty\fP
788 ^@@(MHETCPATH)/mtstailor~^tailor file
793 Versions of \fIMMDF\fR with the \fImaildelivery\fR mechanism aren't
794 entirely backwards\-compatible with earlier versions.
795 If you have an old\-style hook, the best you can do is to have a one\-line
796 \fI\&.maildelivery\fR file:
799 default \- pipe A \*(lqbin/rcvmail $(address) $(info) $(sender)\*(rq
811 .\" @@(#)$Id: slocal.rf,v 1.3 1992/02/11 23:48:28 jromine Exp jromine $
824 \fISlocal\fP sets a number of variables which are
825 available as arguments to the programs invoked by \fIslocal\fP.
826 The default values of these parameters may be overridden
827 by command line arguments to \fIslocal\fP.
834 The destination address.
835 This is obtained from the message envelope delivery information, if possible.
836 If not present, the login name of the uid invoking slocal.
840 The mbox part of \*(lqaddress\*(rq, else the value of \*(lqaddress\*rq.
844 The user's home directory. This sets
848 The user's maildrop file, if not \*(lq@@(MHDROPLOC)\*(rq.
852 The file from which to read the message, if not stdin.
857 This is obtained from the message envelope delivery information, if possible.
858 Under \fISendMail\fP, it is
859 obtained from the UUCP \*(lqFrom \*(rq line, if present.
861 The `\-maildelivery' switch sets the name of the
862 maildelivery file to read instructions from.
865 The `\-debug' switch produces verbose debugging output, printed on stderr.
868 | @@(MHETCPATH)/slocal -user username
871 \fIsource\fR: the out\-of\-band sender information
874 \fIaddr\fR: the address that was used to cause delivery to the recipient
877 \fIdefault\fR: this matches \fIonly\fR if the message hasn't been delivered yet
880 \fI*\fR: this always matches
884 \fBaction\fR: The action to take to deliver the message:
890 \fIfile\fR or \fI>\fR: Append
895 \fImbox\fR: Identical
899 \fIpipe\fR or \fI|\fR: Pipe
903 $(sender): the return address for the message
906 $(address): the address that was used to cause delivery to the recipient
909 $(size): the size of the message in bytes
912 $(reply\-to): either the \*(lqReply\-To:\*(rq or \*(lqFrom:\*(rq field
915 $(info): miscellaneous out\-of\-band information
920 the user/group id:s are set to recipient's id:s;
923 \fIqpipe\fR or \fI<caret>\fR:
925 Similar to \fIpipe\fR,
926 but executes the command directly,
927 after built\-in variable expansion,
928 without assistance from the shell.
933 This action always succeeds.
939 Indicates how the action should be performed:
946 If the action succeeds, then the message is considered delivered.
952 Regardless of the outcome of the action,
953 the message is not considered delivered.
958 Perform the action only if the message has not been delivered.
959 If the action succeeds, then the message is considered delivered.
964 Perform the action only if the message has not been delivered
965 and the previous action succeeded.
966 If this action succeeds, then the message is considered delivered.
972 then standard delivery to the user's maildrop, @@(MHDROPLOC), is performed.
974 Arguments in the \fI\&.maildelivery\fR file are separated by white\-space or
976 Since double\-quotes are honored,
977 these characters may be included in a single argument by enclosing the
978 entire argument in double\-quotes.
979 A double\-quote can be included by preceeding it with a backslash.
981 To summarize, here's an example:
985 .ta \w'default 'u +\w'uk-mmdf-workers 'u +\w'action 'u +\w'result 'u
986 #\fIfield\fR \fIpattern\fR \fIaction\fR \fIresult\fR \fIstring\fR
987 # lines starting with a '#' are ignored, as are blank lines
989 # file mail with mmdf2 in the \*(lqTo:\*(rq line into file mmdf2.log
990 To mmdf2 file A mmdf2.log
991 # Messages from mmdf pipe to the program err-message-archive
992 From mmdf pipe A err-message-archive
993 # Anything with the \*(lqSender:\*(rq address \*(lquk-mmdf-workers\*(rq
994 # file in mmdf2.log if not filed already
995 Sender uk-mmdf-workers file ? mmdf2.log
996 # \*(lqTo:\*(rq unix \- put in file unix-news
997 To Unix > A unix-news
998 # if the address is jpo=mmdf \- pipe into mmdf-redist
999 addr jpo=mmdf | A mmdf-redist
1000 # if the address is jpo=ack \- send an acknowledgement copy back
1001 addr jpo=ack | R \*(lqresend\0\-r\0$(reply-to)\*(rq
1002 # anything from steve \- destroy!
1003 From steve destroy A \-
1004 # anything not matched yet \- put into mailbox
1005 default \- > ? mailbox
1006 # always run rcvalert
1014 \fIaddress\fP is the user invoking \fIslocal\fP
1016 \fIuser\fP is the same as \fIaddress\fP
1019 For compatibility with older versions of \fIMH\fR,
1020 if \fIslocal\fR can't find the user's \fI\&.maildelivery\fR file,
1021 it will attempt to execute an old\-style rcvmail hook in the user's $HOME
1024 it will first attempt to execute
1027 \&.mh\(rureceive file maildrop directory user
1029 failing that it will attempt to execute
1032 $HOME/bin/rcvmail user file sender
1034 before giving up and writing to the user's maildrop.
1037 whenever a hook or process is invoked,
1038 file\-descriptor three (3) is set to the message in addition to the standard
1055 .\" @@(#)$Id: slocal.rf,v 1.1 1992/02/11 21:45:43 jromine Exp jromine $
1059 This file is read by \*(SL.
1062 The format of each line in the \fI\&.maildelivery\fR file is
1065 \fBfield pattern action result string\fR
1075 The name of a header field that is to be searched for a pattern.
1078 In addition, the following special fields are also defined:
1080 \fIsource\fR: the out\-of\-band sender information
1082 \fIaddr\fR: the address that was used to cause delivery to the recipient
1084 \fIdefault\fR: this matches \fIonly\fR if the message hasn't been delivered yet
1086 \fI*\fR: this always matches
1093 The sequence of characters to match in the specified field.
1094 Matching is case\-insensitive but not RE\-based.
1100 The action to take to deliver the message.
1105 \fIfile\fR or \fI>\fR:
1107 Append the message to the file named by \fBstring\fR.
1110 a new field is added:
1113 Delivery\-Date:\ date
1120 Identical to \fIfile\fR,
1123 \fIpipe\fR or \fI|\fR:
1125 Pipe the message as the standard input to the command named by \fBstring\fR,
1129 $(sender): the return address for the message
1131 $(address): the address that was used to cause delivery to the recipient
1133 $(size): the size of the message in bytes
1135 $(reply\-to): either the \*(lqReply\-To:\*(rq or \*(lqFrom:\*(rq field
1139 $(info): miscellaneous out\-of\-band information
1151 @@(MHETCPATH)/slocal \%[addr\ info\ sender]
1157 \%[\-home\ directory]
1158 \%[\-maildelivery\ file]
1167 The destination address.
1168 This is obtained from the message envelope delivery information, if possible.
1169 If not present, the login name of the uid invoking slocal.
1173 The mbox part of "addr", else the value of "addr"
1177 The user's maildrop file, if not \*(lq@@(MHDROPLOC)\*(rq.
1181 The user's home directory.
1185 The file from which to read the message, if not stdin.
1190 This is obtained from the message envelope delivery information, if possible.
1191 Under \fISendMail\fP, it is
1192 obtained from the UUCP \*(lqFrom \*(rq line, if present.
1194 \-maildelivery\ file
1196 The maildelivery file to read instructions from.
1200 Give information on stdout about the progress of slocal.
1204 Verbose debugging output, printed on stderr.
1205 Helpful when debugging your .maildelivery file.
1217 .\" @@(#)$Id: mhook.rf,v 1.10 1992/02/10 20:00:15 jromine Exp $
1220 mhook \- MH receive\-mail hooks
1223 $HOME/\&.maildelivery
1233 .ds SL the local channel
1242 @@(MHETCPATH)/rcvdist
1243 \%[\-form\ formfile]
1244 \%[switches\ for\ \fIpostproc\fR]
1250 @@(MHETCPATH)/rcvpack
1256 @@(MHETCPATH)/rcvtty
1258 \%[\-form\ formatfile]
1259 \%[\-format\ string]
1260 \%[\-bell] \%[\-nobell]
1261 \%[\-newline] \%[\-nonewline]
1265 A receive\-mail hook is a program that is run whenever you receive a
1267 You do \fBNOT\fR invoke the hook yourself,
1269 rather the hook is invoked on your behalf by \fIMH\fR.
1272 rather the hook is invoked on your behalf by \fIMMDF\fR
1273 when you (symbolically) link @@(MHETCPATH)/slocal to the file
1274 bin/rcvmail in your home directory.
1277 rather the hook is invoked on your behalf by \fIMMDF\fR.
1280 rather the hook is invoked on your behalf by \fISendMail\fR,
1281 when you include the line
1284 \*(lq| @@(MHETCPATH)/slocal -user username\*(rq
1291 .if '\*(ZS'slocal' \{\
1294 The name of a field that is to be searched for a pattern.
1297 .if '\*(ZS'mmdfII' \{\
1298 See \fImaildelivery\fR\0(5) for the details.
1301 Four programs are currently standardly available,
1302 \fIrcvdist\fR (redistribute incoming messages to additional recipients),
1303 \fIrcvpack\fR (save incoming messages in a \fIpackf\fR'd file),
1304 and \fIrcvtty\fR (notify user of incoming messages).
1306 \fIrcvstore\fR\0(1) is described separately.
1307 They all reside in the \fI@@(MHETCPATH)/\fR directory.
1309 The \fIrcvdist\fR program will resend a copy of the message to all of the
1310 addresses listed on its command line.
1311 It uses the format string facility described in \fImh\-format\fR\0(5).
1313 The \fIrcvpack\fR program will append a copy of the message to the file listed
1314 on its command line.
1315 Its use is obsoleted by the \fI\&.maildelivery\fR.
1317 The \fIrcvtty\fR program executes the named file with the message as its
1319 and writes the resulting output
1322 If no file is specified, or is bogus, etc.,
1323 then \fIrcvtty\fR will instead write a one\-line scan listing.
1324 Either the `\-form\ formatfile' or `\-format\ string' option may be used
1325 to override the default output format (see \fImh\-format\fP\0(5)).
1326 A newline is output before the
1327 message output, and the terminal bell is rung
1328 after the output. The `\-nonewline' and `\-nobell' options
1329 will inhibit these functions.
1331 Normally, \fIrcvtty\fP obeys
1332 write permission as granted by \fImesg\fP\0(1).
1333 With the `\-biff' option, \fIrcvtty\fP will obey the notification
1334 status set by \fIbiff\fP\0(1).
1335 If the terminal access daemon (TTYD) is available on your system,
1336 then \fIrcvtty\fR will give its output to the daemon for output
1337 instead of writing on the user's terminal.
1341 .if '\*(ZS'slocal' \{\
1342 rcvstore (1), mh\-format(5)
1344 .if '\*(ZS'mmdfII' \{\
1345 rcvstore (1), maildelivery(5), mh\-format(5)
1348 .if '\*(ZS'slocal' \{\
1350 .if '\*(ZS'mmdfII' \{\