Contributed the manpage
[infodrom/newmail] / newmail.1
1 .\"  Copyright (c) 2004  Joey Schulze <joey@infodrom.org>
2 .\"
3 .\"  This program is free software; you can redistribute it and/or modify
4 .\"  it under the terms of the GNU General Public License as published by
5 .\"  the Free Software Foundation; either version 2 of the License, or
6 .\"  (at your option) any later version.
7 .\"
8 .\"  This program is distributed in the hope that it will be useful,
9 .\"  but WITHOUT ANY WARRANTY; without even the implied warranty of
10 .\"  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
11 .\"  GNU General Public License for more details.
12 .\"
13 .\"  You should have received a copy of the GNU General Public License
14 .\"  along with this program; if not, write to the Free Software
15 .\"  Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
16 .\"
17 .TH NEWMAIL 1 "November 22nd, 2004" "Infodrom Oldenburg" "Mail Utilities"
18 .SH NAME
19 newmail \- biff like tool for the terminal
20 .SH SYNOPSIS
21 .B newmail
22 .RB [ \-b ]
23 .RB [ \-h ]
24 .RB [ "\-i \fIinterval\fB" ]
25 .RB [ \-r ]
26 .RB [ \-w ]
27 .RI [ " mbox " [...]]
28 .SH DESCRIPTION
29 The newmail program monitors a given set of mailboxes and looks for
30 new mail.  If new mail is received the sender and subject will be
31 written on the terminal it was started from.  By default
32 .B newmail
33 puts itself in the background so the console is still usable.
34
35 .B newmail
36 is able to monitor arbitrary numbers of mailbox files.  If no mailbox
37 was specified on the commandline it will monitor the default mailbox,
38 which may be overwritten by the
39 .B MAIL
40 environment variable.
41
42 If more than one mailbox is being monitored, a prefix is printed for
43 each mail line so the user can distinguish between the different
44 mailbox files.  By default the prefix is the name of the mailbox
45 without its path.
46
47 If a mailbox is specified as
48 .IR path = string
49 then
50 .I string
51 will be used as prefix for mails received in the mailbox denoted by
52 .IR path .
53 .SH OPTIONS
54 .TP
55 .B \-b
56 Ring a bell after one or more incoming mails have been detected for at
57 least one mailbox.
58 .TP
59 .B \-h
60 Print a help message.
61 .TP
62 .BI \-i " interval"
63 Set the interval between two mailbox checks to
64 .IR interval "seconds."
65 The default is 60 seconds which is suffient for the terminal.  For the
66 use inside of a window or dock application a lower value may be
67 prudent.
68 .TP
69 .B \-r
70 Emit raw data from the mail.  This will bypass routines to decode
71 character encodings used for mail headers.  This may be useful for
72 window applications that want to decode the strings on their own.
73 Since these routines aren't implemented yet, this is the default
74 behaviour.
75 .TP
76 .B \-w
77 Run as window application.  This will prevent
78 .B newmail
79 from putting it self into the background so its output can be used as
80 input for a window application.  This will also change the output
81 format slightly and prevent a bell to be rung after new mail has been
82 received.
83 .SH "OUTPUT FORMAT"
84 The output format differs from being read by humans and programs
85 .RB ( \-w ).
86
87     newmail:
88        >> New mail from <from> - <subject>
89        >> Priority mail from <from> - <subject>
90     
91        >> <folder>: New mail from <from> - <subject>
92        >> <folder>: Priority mail from <from> - <subject>
93     
94     newmail -w:
95        <from> - <subject>
96        Priority: <from> - <subject>
97     
98        <folder>: <from> - <subject>
99        <folder>: Priority: <from> - <subject>
100
101 It should be easy for third party programs which are interested in such
102 information to parse the output when
103 .B newmail
104 is running with the
105 .B \-w
106 option.
107 .SH ENVIRONMENT
108 .B newmail
109 supports the following environment variables:
110 .TP
111 MAIL
112 Full path of the user's spool mailbox.
113 .SH NOTES
114 This program is inspired by the
115 .B newmail
116 program from the Elm interactive mail program.  It is a rewrite from
117 scratch though.
118
119 Many thanks go to Dave Taylor and the Elm Development Group who have
120 provided me with a great mail program for several years.  Many
121 additional thanks go to the former lead developer Dave Taylor who
122 started the program back in 1986.
123 .SH AUTHOR
124 Joey Schulze <joey@infodrom.org>