1DBFORMMAIL(1)         User Contributed Perl Documentation        DBFORMMAIL(1)
2
3
4

NAME

6       dbformmail - write a shell script that will send e-mail to many people
7

SYNOPSIS

9       dbformmail [-m MECHANISM] format_file.txt
10

DESCRIPTION

12       Read a ``form mail'' message from the file FORMAT_FILE.TXT, filling in
13       underscore-preceded column-names with data.  Output a shell script
14       which will send each message through some mail transport MECHANISM.
15
16       Do not use this program for evil or I will have to come over and have
17       words with you.
18
19       Note that this program does NOT actually SEND the mail.  It writes a
20       shell script that will send the mail for you.  I recommend you save it
21       to a file, check it (one last time!), then run it with sh.
22
23       Unlike most Fsdb programs, this program does not output a FSDB file.
24

OPTIONS

26       -m MECHANISM
27           Select the mail-sending mechanism.  Choose "Mail" or "sendmail".
28           Defaults to "Mail".
29
30       This module also supports the standard fsdb options:
31
32       -d  Enable debugging output.
33
34       -i or --input InputSource
35           Read from InputSource, typically a file name, or "-" for standard
36           input, or (if in Perl) a IO::Handle, Fsdb::IO or Fsdb::BoundedQueue
37           objects.
38
39       -o or --output OutputDestination
40           Write to OutputDestination, typically a file name, or "-" for
41           standard output, or (if in Perl) a IO::Handle, Fsdb::IO or
42           Fsdb::BoundedQueue objects.
43
44       --autorun or --noautorun
45           By default, programs process automatically, but Fsdb::Filter
46           objects in Perl do not run until you invoke the run() method.  The
47           "--(no)autorun" option controls that behavior within Perl.
48
49       --help
50           Show help.
51
52       --man
53           Show full manual.
54

SAMPLE USAGE

56   Input:
57           #fsdb account passwd uid gid fullname homedir shell
58           johnh * 2274 134 John_Heidemann /home/johnh /bin/bash
59           greg * 2275 134 Greg_Johnson /home/greg /bin/bash
60           root * 0 0 Root /root /bin/bash
61           # this is a simple database
62
63       Sample form (in the file form.txt):
64
65           To: _account
66           From: the sysadmin <root>
67           Subject: time to change your password
68
69           Please change your password regularly.
70           Doesn't this message make you feel safer?
71
72   Command:
73           cat DATA/passwd.fsdb | dbformmail form.txt >outgoing.sh
74
75   Output (in outgoing.sh):
76           #!/bin/sh
77           sendmail 'johnh' <<'END'
78           To: johnh
79           From: the sysadmin <root>
80           Subject: time to change your password
81
82           Please change your password regularly.
83           Doesn't this message make you feel safer?
84
85           END
86           sendmail 'greg' <<'END'
87           (etc.)
88
89       And to send the mail, run
90
91           sh outgoing.sh
92

SEE ALSO

94       Fsdb.
95
97       Copyright (C) 1991-2018 by John Heidemann <johnh@isi.edu>
98
99       This program is distributed under terms of the GNU general public
100       license, version 2.  See the file COPYING with the distribution for
101       details.
102
103
104
105perl v5.28.1                      2018-12-21                     DBFORMMAIL(1)
Impressum