I wrote about changing .forward:
| >As it turned out, there was [some harm].
Hal Wine responded,
| Well, no accounting for some systems.....
|
| OTOH, here's an approach that should work: use INCLUDERC.
|
| I'd set up my "real" recipes in a file called something other than
| .procmailrc, e.g. .procrc.main
|
| Then, the .procmailrc could look like:
| DOTFWD=yes
| INCLUDERC=$HOME/.procrc.main
So every time I call procmail interactively I'm supposed to remember to
specify .procrc.main on the command line? No thanks. And what about the
aliases that translate to pipes to procmail -a something -d dattier, where
the rcfile has to be ~dattier/.procmailrc but it didn't go through my
.forward and I do not want DOTFWD set to yes? If anything, I'd rather
specify an rcfile in .forward where I can type in its name only once:
"|IFS=' ' && exec /path/to/procmail -f- .forwardrc || exit 75 #dattier"
where ~/.forwardrc would say
DOTFWD=yes
INCLUDERC=$HOME/.procmailrc
[or better yet, .forwardrc would be a hard link to .procmailrc as I explain
below].
| Similarly, I'd set up other wrappers like .procrc.cron, .procrc.alias
| which could set up specific flags and otherwise "normalize" the
| environment before calling the main rc file.
Ah, but my disk use increases by a full kilobyte for every little non-empty
file I have, so I use two other approaches for that function. Early in
~/.procmailrc I have this:
NOTAG=NOTAG TAG
:0
* $ ! ${1+!}
{ TAG=$1 NOTAG }
RCFILE=$_
That way I can ...
1. use the -a option to pass an identifier to procmail and have all the
required flags and variables set up in .procmailrc upon recognition of
certain values in $TAG; and
2. make additional hard links to ~/.procmailrc and have all the required
flags and variables set up in .procmailrc upon recognition of certain
values of $RCFILE.
But although both solve the problem of extra disk space, each requires extra
text on the command line, so I would want the case that I type the most
frequently to require the least typing. Procmail may get invoked most
often through my .forward, but I don't have to type out the command line when
it does.