Automated generation of mh-chart.man7.
[mmh] / man / prompter.man1
1 .\"
2 .\" %nmhwarning%
3 .\"
4 .TH PROMPTER %manext1% "%nmhdate%" MH.6.8 [%nmhversion%]
5 .SH NAME
6 prompter \- prompting editor front-end for nmh
7 .SH SYNOPSIS
8 .HP 5
9 .na
10 .B prompter
11 .RB [ \-erase
12 .IR chr ]
13 .RB [ \-kill
14 .IR chr ]
15 .RB [ \-prepend " | " \-noprepend ]
16 .RB [ \-rapid " | " \-norapid ]
17 .RB [ \-doteof " | " \-nodoteof ]
18 .I file
19 .RB [ \-version ]
20 .RB [ \-help ]
21 .ad
22 .SH DESCRIPTION
23 .B Prompter
24 is an editor front\-end for
25 .B nmh
26 which allows rapid
27 composition of messages.  This program is not normally invoked directly by
28 users but takes the place of an editor and acts as an editor front\-end.
29 It operates on an RFC\-822 style message draft skeleton specified by
30 .IR file ,
31 normally provided by the
32 .B nmh
33 commands
34 .BR comp ,
35 .BR dist ,
36 .BR forw ,
37 or
38 .BR repl .
39 .PP
40 .B Prompter
41 is particularly useful when composing messages over slow
42 network or modem lines.  It is an
43 .B nmh program in that it can have
44 its own profile entry with switches, but it is not invoked directly by
45 the user.  The commands
46 .BR comp ,
47 .BR dist ,
48 .BR forw ,
49 and
50 .B repl
51 invoke
52 .B prompter as an editor, either when invoked with
53 .B \-editor
54 .IR prompter ,
55 or by the profile entry \*(lqEditor:\ prompter\*(rq,
56 or when given the command
57 .B edit
58 .B prompter
59 at the \*(lqWhat now?\*(rq prompt.
60 .PP
61 For each empty component
62 .B prompter finds in the draft, the user
63 is prompted for a response; A <RETURN> will cause the whole component
64 to be left out.  Otherwise, a `\\' preceding a <RETURN> will continue
65 the response on the next line, allowing for multiline components.
66 Continuation lines
67 .B must
68 begin with a space or tab.
69 .PP
70 Each non\-empty component is copied to the draft and displayed on the
71 terminal.
72 .PP
73 The start of the message body is denoted by a blank line or a line
74 of dashes.  If the body is non\-empty, the prompt, which isn't written
75 to the file, is
76 .PP
77 .RS 5
78 --------Enter additional text
79 .RE
80 .PP
81 or (if
82 .B \-prepend
83 was given)
84 .PP
85 .RS 5
86 --------Enter initial text
87 .RE
88 .PP
89 Message\-body typing is terminated with an end\-of\-file (usually
90 CTRL\-D).  With the
91 .B \-doteof
92 switch, a period on a line all by itself
93 also signifies end\-of\-file.  At this point control is returned to
94 the calling program, where the user is asked \*(lqWhat now?\*(rq.
95 See
96 .B whatnow (1)
97 for the valid options to this query.
98 .PP
99 By using the
100 .B \-prepend
101 switch, the user can add type\-in to the
102 beginning of the message body and have the rest of the body follow.
103 This is useful for the
104 .B forw
105 command.
106 .PP
107 By using the
108 .B \-rapid
109 switch, if the draft already contains text in
110 the message\-body, it is not displayed on the user's terminal.  This is
111 useful for low\-speed terminals.
112 .PP
113 The line editing characters for kill and erase may be specified by the
114 user via the arguments
115 .B \-kill
116 .I chr
117 and
118 .B \-erase
119 .IR chr ,
120 where
121 .I chr
122 may be a character; or `\\nnn', where \*(lqnnn\*(rq is the octal value for
123 the character.
124 .PP
125 An interrupt (usually CTRL\-C) during component typing will abort
126 .B prompter
127 and the
128 .B nmh
129 command that invoked it.  An interrupt
130 during message\-body typing is equivalent to CTRL\-D, for historical
131 reasons.  This means that
132 .B prompter
133 should finish up and exit.
134 .PP
135 The first non\-flag argument to
136 .B prompter is taken as the name of
137 the draft file, and subsequent non\-flag arguments are ignored.
138 .\" (\fIRepl\fR invokes editors with two file arguments:
139 .\" the draft file name and the replied\-to message file name.)
140
141 .SH FILES
142 .fc ^ ~
143 .nf
144 .ta \w'%etcdir%/ExtraBigFileName  'u
145 ^$HOME/.mmh/profile~^The user profile
146 ^/tmp/prompter*~^Temporary copy of message
147 .fi
148
149 .SH "PROFILE COMPONENTS"
150 .fc ^ ~
151 .nf
152 .ta 2.4i
153 .ta \w'ExtraBigProfileName  'u
154 prompter\-next: To name the editor to be used on exit from .B prompter
155 ^Msg\-Protect:~^To set mode when creating a new draft
156 .fi
157
158 .SH "SEE ALSO"
159 comp(1), dist(1), forw(1), repl(1), whatnow(1)
160
161 .SH DEFAULTS
162 .nf
163 .RB ` \-prepend '
164 .RB ` \-norapid '
165 .RB ` \-nodoteof '
166 .fi
167
168 .SH CONTEXT
169 None
170
171 .SH "HELPFUL HINTS"
172 The
173 .B \-rapid
174 option is particularly useful with
175 .BR forw ,
176 and
177 .B \-noprepend
178 is useful with
179 .B comp
180 .BR \-use .
181 .PP
182 The user may wish to link
183 .B prompter under several names (e.g.,
184 \*(lqrapid\*(rq) and give appropriate switches in the profile entries
185 under these names (e.g., \*(lqrapid: -rapid\*(rq).  This facilitates
186 invoking prompter differently for different
187 .B nmh
188 commands (e.g.,
189 \*(lqforw: -editor rapid\*(rq).
190
191 .SH BUGS
192 .B Prompter
193 uses
194 .BR stdio (3),
195 so it will lose if you edit files with nulls in them.