File: maildirwatch.1

package info (click to toggle)
manpages-l10n 4.27.0-1~bpo12%2B1
  • links: PTS, VCS
  • area: main
  • in suites: bookworm-backports
  • size: 1,001,980 kB
  • sloc: sh: 4,067; makefile: 913; python: 885; perl: 442; sed: 16; lisp: 3
file content (120 lines) | stat: -rw-r--r-- 3,435 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
'\" t
.\"<!-- Copyright 2021 Double Precision, Inc.  See COPYING for -->
.\"<!-- distribution information. -->
.\"     Title: maildirwatch
.\"    Author: Sam Varshavchik
.\" Generator: DocBook XSL Stylesheets vsnapshot <http://docbook.sf.net/>
.\"      Date: 02/18/2021
.\"    Manual: Double Precision, Inc.
.\"    Source: Courier Mail Server
.\"  Language: English
.\"
.TH "MAILDIRWATCH" "1" "02/18/2021" "Courier Mail Server" "Double Precision, Inc\&."
.\" -----------------------------------------------------------------
.\" * Define some portability stuff
.\" -----------------------------------------------------------------
.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.\" http://bugs.debian.org/507673
.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html
.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.ie \n(.g .ds Aq \(aq
.el       .ds Aq '
.\" -----------------------------------------------------------------
.\" * set default formatting
.\" -----------------------------------------------------------------
.\" disable hyphenation
.nh
.\" disable justification (adjust text to left margin only)
.ad l
.\" -----------------------------------------------------------------
.\" * MAIN CONTENT STARTS HERE *
.\" -----------------------------------------------------------------
.SH "NAME"
maildirwatch \- wait for changes to a maildir
.SH "SYNOPSIS"
.HP \w'\fBmaildirwatch\fR\ 'u
\fBmaildirwatch\fR {\fImaildir\fR} {\fIcommand\fR} [\fIargument\fR...]
.SH "DESCRIPTION"
.PP
\fBmaildirwatch\fR
repeatedly invokes the
\fB\fIcommand\fR\fR, with any optional
\fB\fIargument\fR\fRs, an external command, as follows:
.sp
.RS 4
.ie n \{\
\h'-04'\(bu\h'+03'\c
.\}
.el \{\
.sp -1
.IP \(bu 2.3
.\}
The first time the
\fB\fIcommand\fR\fR
gets executed is immediately after
\fBmaildirwatch\fR
starts\&.
.RE
.sp
.RS 4
.ie n \{\
\h'-04'\(bu\h'+03'\c
.\}
.el \{\
.sp -1
.IP \(bu 2.3
.\}
Subsequent invocatons of
\fB\fIcommand\fR\fR
occur whenever there
\fImay\fR
be some kind of a change to the contents of the
\fImaildir\fR\&.
.sp
\fBmaildirwatch\fR
does not determine what, if anything, changed in the
\fImaildir\fR\&.
\fBmaildirwatch\fR
might occasionally raise a false alarm and run the
\fB\fIcommand\fR\fR
even though nothing changed, but that\*(Aqs rare\&. It\*(Aqs also possible that by the time
\fB\fIcommand\fR\fR
actually runs, then whatever was changed in the
\fImaildir\fR
is no longer changed; it became what it was before it was changed (a mystery that will remain unsolved forever)\&. It\*(Aqs up to the
\fB\fIcommand\fR\fR
to intelligently figure out if it needs to do something about whatever it finds in the
\fImaildir\fR\&.
.RE
.PP
\fBmaildirwatch\fR
is a rudimentary mechanism for writing shell scripts that deal with newly\-delivered mail, in some form or fashion\&.
.SH "EXIT CODE"
.PP
A non\-zero exit code indicates that the specified
\fImaildir\fR
does not exist or is corrupted\&.
.PP
Otherwise
\fBmaildirwatch\fR
runs until the
\fB\fIcommand\fR\fR
exits with a non\-zero exit code\&.
\fBmaildirwatch\fR
prints
\fB\fIcommand\fR\fR\*(Aqs exit code on standard output, and terminates with an exit code of 0\&.
.SH "SEE ALSO"
.PP
\m[blue]\fB\fBmaildirmake\fR(1)\fR\m[]\&\s-2\u[1]\d\s+2\&.
.SH "AUTHOR"
.PP
\fBSam Varshavchik\fR
.RS 4
Author
.RE
.SH "NOTES"
.IP " 1." 4
\fBmaildirmake\fR(1)
.RS 4
\%[set $man.base.url.for.relative.links]/maildirmake.html
.RE