mhstore -auto: Never store into subdirs, but use basename of filename.
[mmh] / man / mhstore.man1
index 61e2ab2..15f4939 100644 (file)
@@ -124,7 +124,22 @@ The
 .B mhstore
 will store the contents of the named messages in
 \*(lqnative\*(rq (decoded) format.  Two things must be determined:
-the directory to store the content, and the filenames.  Files are
+the directory to store the content, and the filenames.
+.PP
+By default (or if the
+.B \-auto
+switch is given),
+.B mhstore
+uses filename information, contained in the message, if available.
+(This information should be specified
+as the attribute \*(lqname=filename\*(rq in the \*(lqContent-Type\*(rq header
+for the content you are storing.)
+Only the basename of this filename is considered.
+If it begins with the character '.', '|', or '!',
+or if it contains the character '%', automatic naming won't happen for
+security reasons. (See below for the fall-back.)
+.PP
+Files are
 written in the directory given by the \*(lqnmh-storage\*(rq profile
 entry, e.g.,
 .PP
@@ -132,31 +147,17 @@ entry, e.g.,
 nmh-storage: /tmp
 .RE
 .PP
+(Note that \*(lqnmh-storage\*(rq is relative to the folder that contains
+the message.)
 If this entry isn't present,
 the current working directory is used.
+Attachments will get stored in either the `nmh-storage' or the current working
+directory \(en in no case elsewhere.
+Existing files get silently overwritten.
 .PP
 If the
-.B \-auto
-switch is given, then
-.B mhstore
-will check if
-the message contains information indicating the filename that should
-be used to store the content.  This information should be specified
-as the attribute \*(lqname=filename\*(rq in the \*(lqContent-Type\*(rq header
-for the content you are storing.  For security reasons, this filename
-will be ignored if it begins with the character '/', '.', '|', or '!',
-or if it contains the character '%'.  For the sake of security,
-this switch is not the default, and it is recommended that you do
-NOT put the
-.B \-auto
-switch in your
-.I \&.mmh/profile
-file.
-.PP
-If the
-.B \-auto
-switch is not given (or is being ignored for security
-reasons) then
+.B \-noauto
+switch is given (or a filename is being ignored for security reasons) then
 .B mhstore
 will look in the user's profile for a
 \*(lqformatting string\*(rq to determine how the different contents
@@ -184,7 +185,7 @@ content is stored in the named folder.  A formatting string consisting
 solely of a \*(lq+\*(rq character is interpreted to be the current
 folder.
 .PP
-If the formatting string consists solely of a \*(lq-\*(rq character,
+If the formatting string consists solely of a \*(lq\-\*(rq character,
 then the content is sent to the standard output.
 .PP
 If the formatting string starts with a '|', then the display string
@@ -200,11 +201,9 @@ escapes (given below) in the display string will be expanded.
 Otherwise the formatting string will represent a pathname in which
 to store the content.  If the formatting string starts with a '/',
 then the content will be stored in the full path given, else the
-file name will be relative to the value of \*(lqnmh-storage\*(rq or
-the current working directory.  Any escapes (given below) will be
-expanded, except for the a-escape.  Note that if \*(lqnmh-storage\*(rq
-is not an absolute path, it will be relative to the folder that
-contains the message(s).
+file name will be relative to either the value of \*(lqnmh-storage\*(rq,
+if set, or the current working directory.
+Existing files get silently overwritten.
 .PP
 A command or pathname formatting string may contain the following
 escapes.  If the content isn't part of a multipart (of any subtype
@@ -385,7 +384,7 @@ mhbuild(1), mhlist(1), mhshow(1), sendfiles(1)
 .nf
 .RB ` +folder "' defaults to the current folder"
 .RB ` msgs "' defaults to cur"
-.RB ` \-noauto '
+.RB ` \-auto '
 
 .SH CONTEXT
 If a folder is given, it will become the current folder.  The last
@@ -393,3 +392,5 @@ message selected will become the current message.
 
 .SH BUGS
 Partial messages contained within a multipart content are not reassembled.
+.PP
+Existing files get silently overwritten.