4 .TH MHPATH %manext1% "%nmhdate%" MH.6.8 [%nmhversion%]
6 mhpath \- print full pathnames of nmh messages and folders
18 expands and sorts the message list `msgs' and writes the full
19 pathnames of the messages to the standard output separated by newlines.
20 If no `msgs' are specified,
22 outputs the current mail folder's pathname
23 instead. If the only argument is `+', your
25 \*(lqPath\*(rq is output; this can be useful in shell scripts.
29 commands, a message argument to
31 may often be intended for writing. Because of this:
34 the name \*(lqnew\*(rq has been added to
37 reserved message names (the others are \*(lqfirst\*(rq, \*(lqlast\*(rq,
38 \*(lqprev\*(rq, \*(lqnext\*(rq, \*(lqcur\*(rq, and \*(lqall\*(rq).
39 The new message is equivalent to the message after the last message
40 in a folder (and equivalent to 1 in a folder without messages).
41 The \*(lqnew\*(rq message may not be used as part of a message range.
43 Within a message list, the following designations may refer to messages
44 that do not exist: a single numeric message name, the single message name
45 \*(lqcur\*(rq, and (obviously) the single message name \*(lqnew\*(rq.
46 All other message designations must refer to at least one existing
47 message, if the folder contains messages.
49 An empty folder is not in itself an error.
51 A message number less than that of the smallest existing message in a
52 folder is treated as if the message already exists. A message number
53 greater than that of the highest existing message in a folder causes
54 an \*(lqout of range\*(rq error message to be displayed.
56 As part of a range designation that contains messages that do exist,
57 message numbers less than the smallest, or greater than the highest,
58 existing message in a folder are ignored.
60 Examples: The current folder foo contains messages 3 5 6.
74 mhpath: message 2001 out of range 1-6
89 mhpath: bad message list last\-new
95 mhpath: no messages in range 1\-2
108 is also useful in back\-quoted operations:
123 .ta \w'%etcdir%/ExtraBigFileName 'u
124 ^$HOME/\&.mh\(ruprofile~^The user profile
127 .SH "PROFILE COMPONENTS"
131 .ta \w'ExtraBigProfileName 'u
132 ^Path:~^To determine the user's nmh directory
133 ^Current\-Folder:~^To find the default current folder
141 .RB ` +folder "' defaults to the current folder"
142 .RB ` msgs "' defaults to none"
165 Quite the reverse. But
169 mv `mhpath 501` `mhpath 500`
175 Out of range message 0 is treated far more severely than large out of
176 range message numbers.