1 .TH MH-ALIAS %manext5% 2014-04-18 "%nmhversion%"
6 mh-alias \- format of nmh alias files
11 alias file takes one of the following forms:
43 .IR address-group " := " address-list
45 .RI " | = " Unix-group
46 .RI " | + " Unix-group
48 .IR address-list " := " address
49 .RI " | " address-list ", " address
53 Continuation lines end with \*(lq\\\*(rq followed by a newline
54 character. This also applies to comment lines. Thus, the line following a
55 \*(lq\\\*(rq-terminated
56 comment line is a continuation of
64 is a group name or number from
65 the system's group database.
66 Alias file contents are case-insensitive, with the exception
67 of filesystem path names.
69 If the line starts with a \*(lq<\*(rq, the file named after the \*(lq<\*(rq is
70 read for more alias definitions. The reading is done recursively, so a
71 \*(lq<\*(rq may occur in the beginning of an alias file with the expected results.
75 starts with a \*(lq<\*(rq, the file named after the
76 \*(lq<\*(rq is read and its contents are added to the
82 starts with an \*(lq=\*(rq, the
83 system's group database
84 is consulted for the Unix-group named after the \*(lq=\*(rq. Each login name
85 occurring as a member of the group is added to the
91 starts with a \*(lq+\*(rq, the system's group database
92 is consulted to determine the group-id of the
93 Unix-group named after the \*(lq+\*(rq. Each login name occurring in the
94 system's password database
95 whose group-id is indicated by this group is
100 In match, a trailing \*(lq*\*(rq on an alias will match just about anything
103 An approximation of the way aliases are resolved at posting time is:
105 Build a list of all addresses from the message to be delivered,
106 eliminating duplicate addresses.
108 For those addresses in the message that have no host specified,
109 perform alias resolution.
111 For each line in the alias file, compare \*(lqalias\*(rq against all of
112 the existing addresses. If a match, remove the matched \*(lqalias\*(rq
113 from the address list, and add each new address in the address-group to
114 the address list if it is not already on the list. The alias itself is
115 not usually output, rather the address-group that the alias maps to is
116 output instead. If \*(lqalias\*(rq is terminated with a \*(lq;\*(rq instead of
117 a \*(lq:\*(rq, then both the \*(lqalias\*(rq and the address are output in the
118 correct format (with the alias quoted if necessary and the address
123 file is read line by line, forward references work, but
124 backward references are not recognized.
130 <%nmhetcdir%/BBoardAliases
131 sgroup: fred, fear, freida
132 fred: frated@UCI.example
133 b-people: Blind List: bill, betty
134 Unix\-committee: <unix.aliases
141 The first line says that more aliases should immediately be read from
143 .BR %nmhetcdir%/BBoardAliases .
144 Next, \*(lqsgroup\*(rq is defined as an alias for three names,
145 and one of them, \*(lqfred\*(rq,
146 is a forward reference to another alias for \*(lqfrated@UCI.example\*(rq.
148 The alias \*(lqb-people\*(rq is a blind list which includes the addresses
149 \*(lqbill\*(rq and \*(lqbetty\*(rq; the message will be delivered to those
150 addresses, but the message header will show only \*(lqBlind List: ;\*(rq
151 (not the addresses). The alias must not be terminated with, or contain,
153 Note that blind lists are not supported with the
155 mail transport method.
157 The definition of \*(lqUnix\-committee\*(rq is given by
164 \*(lqstaff\*(rq is defined as all users who are listed as members of the
165 group \*(lqstaff\*(rq in the
166 system's group database, and \*(lqwheels\*(rq
167 is defined as all users whose group-id in
168 the system's password database
169 is equivalent to the \*(lqwheel\*(rq group.
172 .RI \*(lqnews. anything \*(rq
173 is aliased to \*(lqnews\*(rq;
174 the full stop is just another literal character.
175 .SH "PROFILE COMPONENTS"
181 %nmhetcdir%/MailAliases
182 System-wide default alias file.
191 Although the forward-referencing semantics of
193 files prevent recursion, the
195 directive may defeat this.
196 Since the number of file descriptors is finite, such
197 infinite recursion will terminate with a meaningless diagnostic when
198 all the fds are used up.
200 Earlier versions of this man page showed a semicolon at the end of the
201 blind list example. That caused the preceding alias to not be
202 expanded. There must not be a semicolon at the end of, or within, the
203 address group of a blind list.
205 will append the semicolon to the blind list name.