1REPL(1)                     General Commands Manual                    REPL(1)
2
3
4

NAME

6       repl - reply to an nmh message
7

SYNOPSIS

9       repl [-help] [-version] [+folder] [msg] [-annotate | -noannotate]
10            [-group | -nogroup] [-cc all/to/cc/me] [-nocc all/to/cc/me]
11            [-query | -noquery] [-form formfile] [-format | -noformat] [-fil‐
12            ter filterfile] [-inplace | -noinplace] [-mime | -nomime] [-fcc
13            +folder] [-width columns] [-draftfolder +folder] [-draftmessage
14            msg] [-nodraftfolder] [-editor editor] [-noedit] [-convertargs
15            type argstring] [-whatnowproc program] [-nowhatnowproc] [-atfile]
16            [-noatfile] [-fmtproc program] [-nofmtproc] [-build] [-file msg‐
17            file]
18

DESCRIPTION

20       repl may be used to reply to a message.
21
22       In  its  simplest form (with no arguments), repl will set up a message-
23       form skeleton in reply to the current message in  the  current  folder,
24       and invoke the whatnow shell.
25
26       repl  uses  a  reply  template  to construct the draft of the reply.  A
27       reply template is simply an  mhl  format  file  (see  mh-format(5)  for
28       details).
29
30       If  the  switch -nogroup is given (it is on by default), then repl will
31       use the standard forms file “replcomps”.  This will construct  a  draft
32       message  that  is intended to be sent only to the author of the message
33       to which you are replying.  If a file named “replcomps” exists  in  the
34       user's  nmh  directory,  it  will be used instead of this default forms
35       file.
36
37       The default reply template “replcomps” will direct  repl  to  construct
38       the reply message draft as follows:
39
40            To: <Mail-Reply-To> or <Reply-To> or <From>
41            cc: <To> and <cc> and <personal address>
42            Fcc: {fcc switch} or +outbox
43            Subject: Re: <Subject>
44            In-Reply-To: <Message-Id>
45            References: <Message-Id>
46            Comments: In-Reply-To <From> or <apparently from> or <Sender>
47               message dated <date>
48            --------
49
50       where  field  names  enclosed in angle brackets (< >) indicate the con‐
51       tents of the named field from the message to which the reply  is  being
52       made.
53
54       By  default,  the  “cc:”  field  is  empty.   You  may  selectively add
55       addresses to this default with the -cc type switch.  This switch  takes
56       an  argument  (all/to/cc/me)  which  specifies  who  gets  added to the
57       default “cc:” list of the reply.  You may  give  this  switch  multiple
58       times  (with  different arguments) if you wish to add multiple types of
59       address.
60
61       If the switch -group is given, then repl will use  the  standard  forms
62       file  “replgroupcomps”.   This  will  construct a draft message that is
63       intended as a group or followup reply.  If  a  file  named  “replgroup‐
64       comps”  exists  in the user's nmh directory, it will be used instead of
65       this default forms file, unless you specify another forms file  on  the
66       command line or in your profile.
67
68       The  default  group reply template “replgroupcomps” will direct repl to
69       construct the reply message draft as follows:
70
71            To: <Mail-Followup-To>
72            Subject: Re: <Subject>
73            In-Reply-To: Message from <From> of <Date>.
74                         <Message-Id>
75            --------
76
77       or if the field <Mail-Followup-To> is not available:
78
79            To: <Mail-Reply-To> or <Reply-To> or <From>
80            cc: <To> and <cc> and <personal address>
81            Subject: Re: <Subject>
82            In-Reply-To: Message from <From> of <Date>.
83                         <Message-Id>
84            --------
85
86       By default, the “cc:” contains all the addresses shown.  You may selec‐
87       tively  remove  addresses from this default with the -nocc type switch.
88       This switch takes an argument ( all/to/cc/me) which specifies who  gets
89       removed  from  the  default “cc:” list of the reply.  You may give this
90       switch multiple times (with different arguments) if you wish to  remove
91       multiple types of address.
92
93       In  any case, you may specify an alternative forms file with the switch
94       -form formfile.
95
96       The -query switch modifies the action of -nocc type switch by  interac‐
97       tively  asking you if each address that normally would be placed in the
98       “To:” and “cc:” list should actually be sent a copy.   This  is  useful
99       for  special-purpose  replies.   Note  that the position of the -cc and
100       -nocc switches, like all other switches which take a positive and nega‐
101       tive form, is important.
102
103       Lines  beginning with the fields “To:”, “cc:”, and ”Bcc:” will be stan‐
104       dardized and have duplicate addresses removed.  In addition, the -width
105       columns switch will guide repl's formatting of these fields.
106
107       If the draft already exists, repl will ask you as to the disposition of
108       the draft.  A reply of quit will abort repl, leaving the draft  intact;
109       replace will replace the existing draft with a blank skeleton; and list
110       will display the draft.
111
112       See comp(1) for a description of  the  -editor  and  -noedit  switches.
113       Note  that  while in the editor, with -atfile and if the current direc‐
114       tory is writable, the message being replied to is available  through  a
115       link  named  “@”  (assuming the default whatnowproc).  In addition, the
116       actual pathname of the message is stored in  the  environment  variable
117       $editalt,  and  the  pathname  of  the folder containing the message is
118       stored in the environment variable $mhfolder.  The creation of the  “@”
119       file is controlled via the -atfile and -noatfile options.
120
121       The  -convertargs switch directs repl to pass the arguments for type to
122       mhbuild.  Both arguments are required; type  must  be  non-empty  while
123       argstring can be empty, e.g., '' in a shell command line.  The -conver‐
124       targs switch can be used multiple times.   See  the  Convert  Interface
125       section  of  mhbuild(1) for a description of the convert mechanism, and
126       /usr/share/doc/nmh/contrib/replaliases for examples of its use.
127
128       Although repl uses a forms file to  direct  it  how  to  construct  the
129       beginning  of  the draft, it uses a message filter file to direct it as
130       to how the message to which you are replying should  be  filtered  (re-
131       formatted)  in  the body of the draft.  The filter file for repl should
132       be a standard form file for mhl, as repl will invoke mhl to format  the
133       message to which you are replying.
134
135       The  switches  -noformat, -format, and -filter filterfile specify which
136       message filter file to use.
137
138       If the switch -noformat is given (it is the default)  and  the  -filter
139       switch  is  not used, then the message to which you are replying is not
140       included in the body of the draft.
141
142       If the switch -format is given, then a default message filter  file  is
143       used.   This  default message filter should be adequate for most users.
144       This default filter “mhl.reply” is:
145
146            ; mhl.reply
147            ;
148            ; default message filter for `repl' (repl -format)
149            ;
150            from:nocomponent,formatfield="%(unquote(decode(friendly{text}))) writes:"
151            body:component="> ",overflowtext="> ",overflowoffset=0
152
153       which outputs each line of the body of the message  prefaced  with  the
154       “>” character and a space.
155
156       If a file named “mhl.reply” exists in the user's nmh directory, it will
157       be used instead of this form.  You may  specify  an  alternate  message
158       filter file with the switch -filter filterfile.
159
160       Other reply filters are commonly used, such as:
161
162            :
163            body:nocomponent,compwidth=9,offset=9
164
165       which  says  to  output  a blank line, and then the body of the message
166       being replied to, indented by one tab stop.  Another popular format is:
167
168            message-id:nocomponent,nonewline,\
169            formatfield=“In message %{text}, ”
170            from:nocomponent,formatfield=“%(decode(friendly{text})) writes:”
171            body:component=“>”,overflowtext=“>”,overflowoffset=0
172
173       This message filter file cites the Message-ID and author of the message
174       being  replied to, and then outputs each line of the body prefaced with
175       the “>” character.
176
177       You can also use an external format program to format the message body.
178       The format program is specified by the formatproc profile entry, and is
179       enabled by the “format” flag.  A message filter using an external  for‐
180       mat program would look like this:
181
182            body:component=“>”,nowrap,format
183
184       See  the mhl(1) documentation for more information.  The format program
185       can be changed by the -fmtproc program and -nofmtproc switches.
186
187       To use the MIME rules for  encapsulation,  specify  the  -mime  switch.
188       This  directs  repl to generate an mhbuild composition file.  Note that
189       nmh will not invoke mhbuild automatically; you must  specifically  give
190       the command
191
192            What now? mime
193
194       prior to sending the draft.
195
196       If  the -annotate switch is given, the message being replied to will be
197       annotated with the lines
198
199            Replied: date Replied: addrs
200
201       where the address list contains one line for each addressee.  The anno‐
202       tation will be done only if the message is sent directly from repl.  If
203       the message is not sent immediately from repl, “comp -use” may be  used
204       to  re-edit and send the constructed message, but the annotations won't
205       take place.  Normally annotations are done inplace in order to preserve
206       any  links to the message.  You may use the -noinplace switch to change
207       this.
208
209       Although the default template specifies that a copy of the  reply  will
210       be  put  in the folder 'outbox', if the -fcc +folder switch is given it
211       will override the default value.  More than one folder,  each  preceded
212       by -fcc can be named.
213
214       In  addition to the standard mh-format(5) escapes, repl also recognizes
215       the following additional component escape:
216
217            Escape  Returns  Description
218            fcc     string   Any folders specified with `-fcc folder'
219
220       To avoid reiteration, repl strips any leading `Re: ' strings  from  the
221       subject component.
222
223       The  -draftfolder +folder and -draftmessage msg switches invoke the nmh
224       draft folder facility.  This is an advanced (and  highly  useful)  fea‐
225       ture.  Consult the mh-draft(5) man page for more information.
226
227       Upon  exiting  from  the  editor, repl will invoke the whatnow program.
228       See whatnow(1) for a discussion of available options.   The  invocation
229       of  this  program  can be inhibited by using the -nowhatnowproc switch.
230       (In fact, it is the whatnow program  which  starts  the  initial  edit.
231       Hence, -nowhatnowproc will prevent any edit from occurring.)
232
233       The -build switch is intended to be used by the Emacs mh-e interface to
234       nmh.  It implies -nowhatnowproc.  It causes a file <mh-dir>/reply to be
235       created,  containing the draft message that would normally be presented
236       to the user for editing.  No mail is actually sent.
237
238       The -file msgfile switch specifies the message to be replied to  as  an
239       exact  filename  rather  than as an nmh folder and message number.  The
240       same caveats apply to this option as to the -build switch.
241

FILES

243       repl looks for all format, filter and template files in multiple  loca‐
244       tions:  absolute  pathnames  are  accessed directly, tilde expansion is
245       done on usernames, and files are searched for in the user's Mail direc‐
246       tory  as specified in their profile.  If not found there, the directory
247/etc/nmh” is checked.
248
249       /etc/nmh/replcomps         The standard reply template
250       or <mh-dir>/replcomps      Rather than the standard template
251       /etc/nmh/replgroupcomps    The standard `reply -group' template
252       or <mh-dir>/replgroupcomps Rather than the standard template
253       /etc/nmh/mhl.reply         The standard message filter
254       or <mh-dir>/mhl.reply      Rather than the standard filter
255       $HOME/.mh_profile          The user profile
256       <mh-dir>/draft             The draft file
257

PROFILE COMPONENTS

259       Path:                To determine the user's nmh directory
260       Alternate-Mailboxes: To determine the user's mailboxes
261       Current-Folder:      To find the default current folder
262       Draft-Folder:        To find the default draft-folder
263       Editor:              To override the default editor
264       Msg-Protect:         To set mode when creating a new message (draft)
265       fileproc:            Program to refile the message
266       mhlproc:             Program to filter message being replied-to
267       whatnowproc:         Program to ask the “What now?” questions
268

SEE ALSO

270       comp(1), forw(1), mh-format(5), mhbuild(1), send(1), whatnow(1)
271
272       /usr/share/doc/nmh/contrib/replaliases
273

DEFAULTS

275       `+folder' defaults to the current folder
276       `msg' defaults to cur
277       `-nogroup'
278       `-nocc all' with `-nogroup', `-cc all' with `-group'
279       `-noannotate'
280       `-nodraftfolder'
281       `-noformat'
282       `-inplace'
283       `-nomime'
284       `-noquery'
285       `-noatfile'
286       `-width 72'
287

CONTEXT

289       If a folder is given, it will become the current folder.   The  message
290       replied to will become the current message.
291

BUGS

293       If any addresses occur in the reply template, addresses in the template
294       that do not contain hosts are defaulted incorrectly.  Instead of  using
295       the  localhost  for the default, repl uses the sender's host.  Moral of
296       the story: if you're going to include addresses in  a  reply  template,
297       include the host portion of the address.
298
299       The  -width  columns  switch  is only used to do address-folding; other
300       headers are not line-wrapped.
301
302       If whatnowproc is whatnow, then repl uses a built-in whatnow,  it  does
303       not  actually  run  the whatnow program.  Hence, if you define your own
304       whatnowproc, don't call it whatnow since repl won't run it.
305
306
307
308nmh-1.7.1                         2014-12-15                           REPL(1)
Impressum