doc: Add README.md
[smailq.git] / smailq.docbook
1 <?xml version="1.0" encoding="utf-8"?>
2
3 <!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook V4.4//EN"
4 "file:///usr/share/xml/docbook/schema/dtd/4.4/docbookx.dtd"
5 []>
6
7 <refentry>
8
9 <refentryinfo>
10 <address>
11 <email>shuber@sthu.org</email>
12 </address>
13 <author>
14 <firstname>Stefan</firstname>
15 <surname>Huber</surname>
16 </author>
17 <date>2013-12-29</date>
18 </refentryinfo>
19
20 <refmeta>
21 <refentrytitle>smailq</refentrytitle>
22 <manvolnum>1</manvolnum>
23 <refmiscinfo>smailq 1.0</refmiscinfo>q
24 </refmeta>
25
26 <refnamediv>
27 <refname><application>smailq</application></refname>
28 <refpurpose>A simple mail queue.</refpurpose>
29 </refnamediv>
30
31 <refsynopsisdiv>
32 <cmdsynopsis>
33 <command>smailq</command>
34 <option>--send</option>
35 <arg rep="repeat"><replaceable>recipient</replaceable></arg>
36 <option>--</option>
37 <arg rep="repeat"><replaceable>MSA options</replaceable></arg>
38 </cmdsynopsis>
39 <cmdsynopsis>
40 <command>smailq</command>
41 <option>--list</option>
42 </cmdsynopsis>
43 <cmdsynopsis>
44 <command>smailq</command>
45 <option>--deliver-all</option>
46 </cmdsynopsis>
47 <cmdsynopsis>
48 <command>smailq</command>
49 <option>--deliver</option>
50 <arg rep="repeat"><replaceable>ID</replaceable></arg>
51 </cmdsynopsis>
52 <cmdsynopsis>
53 <command>smailq</command>
54 <option>--delete</option>
55 <arg rep="repeat"><replaceable>ID</replaceable></arg>
56 </cmdsynopsis>
57 <cmdsynopsis>
58 <command>smailq</command>
59 <option>--help</option>
60 </cmdsynopsis>
61 <cmdsynopsis>
62 <command>smailq</command>
63 <option>--version</option>
64 </cmdsynopsis>
65 </refsynopsisdiv>
66
67 <refsect1>
68 <title>DESCRIPTION</title>
69
70 <para>
71 <command>smailq</command> is a mail queue for lightweight SMTP
72 clients (MSAs) like msmtp that do not provide a queue. It basically
73 provides the functionality of sendmail and mailq.
74 </para>
75
76 <para>
77 When <command>smailq</command> sends a mail it first inserts the
78 mail into the message queue and then attempts to deliver all mails
79 in the queue using an external MSA such as msmtp.
80 </para>
81
82 </refsect1>
83
84 <refsect1>
85 <title>COMMANDS</title>
86
87 <variablelist>
88
89 <varlistentry>
90 <term><option>--delete</option></term>
91 <listitem>
92 <para>Remove the mails with given IDs from the queue.</para>
93 </listitem>
94 </varlistentry>
95
96 <varlistentry>
97 <term><option>--deliver</option></term>
98 <listitem>
99 <para>Attempt to deliver the mails with given IDs only.</para>
100 </listitem>
101 </varlistentry>
102
103 <varlistentry>
104 <term><option>--deliver-all</option></term>
105 <listitem>
106 <para>Attempt to deliver all mails in the queue.</para>
107 </listitem>
108 </varlistentry>
109
110 <varlistentry>
111 <term><option>-h</option></term>
112 <term><option>--help</option></term>
113 <listitem>
114 <para>Print usage text.</para>
115 </listitem>
116 </varlistentry>
117
118 <varlistentry>
119 <term><option>--list</option></term>
120 <listitem>
121 <para>List all mails in the queue. This is the default.</para>
122 </listitem>
123 </varlistentry>
124
125 <varlistentry>
126 <term><option>--send</option></term>
127 <listitem>
128 <para>Read a mail from stdin, insert it into the queue, and
129 attempt to deliver all mails in the queue. Options after
130 "--" are passed forward to the MSA for this particular
131 mail.</para>
132 </listitem>
133 </varlistentry>
134
135 <varlistentry>
136 <term><option>-V</option></term>
137 <term><option>--version</option></term>
138 <listitem>
139 <para>Show version info.</para>
140 </listitem>
141 </varlistentry>
142
143 </variablelist>
144 </refsect1>
145
146
147 <refsect1>
148 <title>OPTIONS</title>
149
150 <variablelist>
151
152 <varlistentry>
153 <term><option>-C</option></term>
154 <term><option>--config FILE</option></term>
155 <listitem>
156 <para>Use the given configuration file instead of
157 "$HOME/.smailq.conf".</para>
158 </listitem>
159 </varlistentry>
160
161 <varlistentry>
162 <term><option>-q</option></term>
163 <term><option>--quiet</option></term>
164 <listitem>
165 <para>Do not print info messages.</para>
166 </listitem>
167 </varlistentry>
168
169 <varlistentry>
170 <term><option>-v</option></term>
171 <term><option>--verbose</option></term>
172 <listitem>
173 <para>Increase output verbosity.</para>
174 </listitem>
175 </varlistentry>
176
177 </variablelist>
178 </refsect1>
179
180 <refsect1>
181 <title>CONFIGURATION FILES</title>
182
183 <para>
184 By default, <command>smailq</command> looks at $HOME/.smailq.conf
185 and /etc/smailq.conf (in that order) for a configuration file,
186 unless the configuration file is explicitly specified by an option.
187 The syntax follows RFC 822. A sample configuration file contains
188 the following lines:
189 </para>
190
191 <programlisting>
192 [general]
193 # Optional: The directory where the log file is written to. The special
194 # value 'syslog' causes smailq to log to syslog.
195 logdir = ~/.smailq/log/
196 # Optional: The directory where smailq saves the mail queue data
197 datadir = ~/.smailq/data/
198
199 # Settings for the network (TCP) connectivity test
200 [nwtest]
201 # Optional: The host to connect to
202 host = www.google.com
203 # Optional: The port to connect to
204 port = 80
205 # Optional: The timeout
206 timeout = 8
207
208 # Settings concerning the mail submission agent
209 [msa]
210 # This command is called when smailq attempts to deliver a mail. The
211 # MSA-options passed to smailq are appended to this line.
212 cmd = /usr/bin/msmtp
213 </programlisting>
214
215 </refsect1>
216
217 <refsect1>
218 <title>BUGS</title>
219 Bug reports to Stefan Huber <email>shuber@sthu.org</email>.
220 </refsect1>
221
222 <refsect1>
223 <title>AUTHOR</title>
224
225 <para>
226 <author>
227 <firstname>Stefan</firstname>
228 <surname>Huber</surname>
229 <contrib>Original author</contrib>
230 <email>shuber@sthu.org</email>
231 </author>
232 </para>
233 </refsect1>
234 </refentry>