MHPATH(1MH) COMMAND REFERENCE MHPATH(1MH)
NAME
mhpath - print full pathnames of MH messages and folders
SYNOPSIS
mhpath [+folder] [msgs] [-help]
DESCRIPTION
Mhpath expands and sorts the message list [msgs] and writes
the full pathnames of the messages to the standard output
separated by newlines.
If no ``msgs'' are specified, mhpath outputs the folder
(directory) pathname (current folder default).
Contrasted with other MH commands, a message argument to
mhpath may often be intended for writing. Because of this:
1) The name new has been added to mhpath's list of reserved
message names (the others are first, last, prev, next,
cur, all). New is last + 1 (where last is 0 in a
messageless folder). New may not be used as part of a
message range.
2) Within a message list, the following designations may
refer to messages that do not exist: a single numeric
message name, the single message name cur, and
(obviously) the single message name new. All other
message designations must refer to at least one existing
message.
3) An empty folder is not in itself an error.
Message numbers greater than 999 as part of a range
designation are replaced with 999. Explicit single message
numbers greater than 999, or message number 0 in any
context, are errors.
Your .mh_profile can contain the following entries:
Path To determine the user's MH directory
Current-Folder
To find the default current folder
mhpath has the following defaults:
+folder defaults to current
msgs defaults to NULL
The folder and the current message are unaffected.
Printed 4/6/89 1
MHPATH(1MH) COMMAND REFERENCE MHPATH(1MH)
OPTIONS
-help Display a synopsis of the mhpath command.
+folder folder becomes the current folder.
EXAMPLES
The current folder, foo, contains messages 3 5 6. Cur is 4.
% mhpath
/r/phyl/Mail/foo
% mhpath all
/r/phyl/Mail/foo/3
/r/phyl/Mail/foo/5
/r/phyl/Mail/foo/6
% mhpath 1000
Message 1000 out of range 1-999
% mhpath 1-1001
/r/phyl/Mail/foo/3
/r/phyl/Mail/foo/5
/r/phyl/Mail/foo/6
% mhpath new
/r/phyl/Mail/foo/7
% mhpath last new
/r/phyl/Mail/foo/6
/r/phyl/Mail/foo/7
% mhpath last-new
Bad message list "last-new".
% mhpath cur
/r/phyl/Mail/foo/4
% mhpath 1-2
No messages in range "1-2".
% mhpath first:2
/r/phyl/Mail/foo/3
/r/phyl/Mail/foo/5
% mhpath 1 2
/r/phyl/Mail/foo/1
/r/phyl/Mail/foo/2
% mhpath 0
Bad message list "0".
% mhpath 0-last
Printed 4/6/89 2
MHPATH(1MH) COMMAND REFERENCE MHPATH(1MH)
Bad message list "0-last".
--Backquoted Operations--
% cd `mhpath +inbox`
From "e":
<CMD> run cat `mhpath cur`
FILES
$HOME/.mh_profile
The user profile
CAVEATS
Like all MH commands, mhpath expands and sorts [msgs].
Don't expect:
mv mhpath 501 500
to move 501 to 500-- the reverse will happen. But:
mv mhpath 501 mhpath 500`
will do the trick.
Out of range message 0 is treated far more severely than
large out of range message numbers.
SEE ALSO
mh(5mh).
Printed 4/6/89 3
%%index%%
na:336,108;
sy:444,347;
de:791,2164;
op:3363,375;
ex:3738,1104;5250,165;
fi:5415,147;
ca:5562,472;
se:6034,124;
%%index%%000000000145