X-Git-Url: http://git.marmaro.de/?a=blobdiff_plain;f=man%2Fmh-format.man;h=aa1c630a79c14c9b15c4b47708867697d2862974;hb=681fb6f84e8094c2c857d4341d3e2fb97d377908;hp=2fdae4b592af587a981a01a716bfbd7d7dba767d;hpb=678a7a83f08b7a3f6cf3a11ea580cd69566eaf1b;p=mmh diff --git a/man/mh-format.man b/man/mh-format.man index 2fdae4b..aa1c630 100644 --- a/man/mh-format.man +++ b/man/mh-format.man @@ -1,6 +1,5 @@ .\" -.\" THIS FILE HAS BEEN AUTOMATICALLY GENERATED. DO NOT EDIT. -.\" $Id$ +.\" %nmhwarning% .\" .TH MH-FORMAT %manext5% "%nmhdate%" MH.6.8 [%nmhversion%] .SH NAME @@ -253,7 +252,9 @@ strlen integer length of \fIstr\fR width integer output buffer size in bytes charleft integer bytes left in output buffer timenow integer seconds since the UNIX epoch -me string the user's mailbox +me string the user's mailbox (username) +myhost string the user's local hostname +myname string the user's name eq literal boolean \fInum\fR == \fIarg\fR ne literal boolean \fInum\fR != \fIarg\fR gt literal boolean \fInum\fR > \fIarg\fR @@ -282,21 +283,40 @@ compval comp integer Set \fInum\fR to \*(lq\fBatoi\fR(\fIcomp\fR\^)\*(rq .\" decodecomp comp string Set \fIstr\fR to RFC-2047 decoded component text decode expr string decode \fIstr\fR as RFC-2047 (MIME-encoded) component +unquote expr string remove RFC-2822 quotes from \fIstr\fR trim expr trim trailing white-space from \fIstr\fR putstr expr print \fIstr\fR putstrf expr print \fIstr\fR in a fixed width putnum expr print \fInum\fR putnumf expr print \fInum\fR in a fixed width .\" addtoseq literal add msg to sequence (LBL option) +putlit expr print \fIstr\fR without space compression nodate string integer Argument not a date string (0 or 1) formataddr expr append \fIarg\fR to \fIstr\fR as a (comma separated) address list +concataddr expr append \fIarg\fR to \fIstr\fR as a + (comma separated) address list, + including duplicates, + see Special Handling putaddr literal print \fIstr\fR address list with \fIarg\fR as optional label; get line width from \fInum\fR .fi .RE .PP +The (\fIme\fR\^) function returns the username of the current user. The +(\fImyhost\fR\^) function returns the +.B localname +entry in +.IR mts.conf , +or the local hostname if +.B localname +is not configured. The (\fImyname\fR\^) function will return the value of +the +.B SIGNATURE +environment variable if set, otherwise will return the passwd GECOS field for +the current user. +.PP The following functions require a date component as an argument: .PP .RS 5 @@ -387,10 +407,24 @@ right-justification of the string within the field, with padding on the left up to the field width. The functions (\fIputnum\fR\^) and (\fIputstr\fR\^) are somewhat special: they print their result in the minimum number of characters -required, and ignore any leading field width argument. +required, and ignore any leading field width argument. The (\fIputlit\fR\^) +function outputs the exact contents of str register without any changes +such as duplicate space removal or control character conversion. .PP The available output width is kept in an internal register; any output past this width will be truncated. +.SS Special Handling +A few functions have different behavior depending on what command they are +being invoked from. +.PP +In +.BR repl +the (\fIformataddr\fR\^) function stores all email addresses encountered into +an internal cache and will use this cache to suppress duplicate addresses. +If you need to create an address list that includes previously-seen +addresses you may use the (\fIconcataddr\fR\^) function, which is identical +to (\fIformataddr\fR\^) in all other respects. Note that (\fIconcataddr\fR\^) +will NOT add addresses to the duplicate-suppression cache. .SS Examples With all this in mind, here's the default format string for