hi there. Just started using nmh and I must say I love it.
Well, thanks! Always good to have a new user.
I'm at the stage where I'd like to customise the templates a little.
So, these are written in a kind of strange little language. It's documented
relatively completely in mh-format(5). As of 1.6 we include fmttest(1)
which you can use to help debug your format script.
My components template file has the line
%<{from}%|%(void(localmbox))%>%(void(width))%(putaddr From: )
How can I change that to: "for From: use the address passed
as the -from switch, or use a(_at_)b(_dot_)com
Well, that already pretty much does that. The %(localmbox) entry uses
the Local-Mailbox profile entry (there is a fallback generated based on
your local username and hostname). So if you put:
Local-Mailbox: My Name <a(_at_)b(_dot_)com>
It should do exactly what you want.
In the same way, my replcomp template has the line
%(void(localmbox))%(void(width))%(putaddr From: )
How can I change that to: "for From: use the "Delivered-to:"
header or a(_at_)b(_dot_)com
Well, the manual would explain that, but it's pretty dense. Here's
something that should work:
%<{delivered-to}%|%(void(localmbox))%>%(void(width))%(putaddr From: )
Again, check out mh-format(5) and fmttest(1); the former explains the
syntax, the latter shows you what the script is doing. You also might find
the information in Jerry Peek's book useful; it's old, but most of it is
still relevant:
http://rand-mh.sourceforge.net/book/
--Ken
_______________________________________________
Nmh-workers mailing list
Nmh-workers(_at_)nongnu(_dot_)org
https://lists.nongnu.org/mailman/listinfo/nmh-workers