Re: copy attachments to two destinations - solved
Eric Smith <[email protected]>
| Newsgroups | gmane.mail.procmail |
|---|---|
| Message-ID | <[email protected]> |
Bart Schaefer wrote on Tue-12-Nov 13 10:44PM
> You don't want the "f" flag. "Consider the pipe as a filter" means
> that procmail will capture the standard output of the pipe and replace
> the message contents with it. Thus with the above, you'll have a
> complete message only for the first pipe, and most likely an empty
> message for the second pipe.
>
> You want the "c" flag on the first recipe, and no flags at all on the
> second one, though you might want to consider establishing a locking
> protocol if attachments having the same name might arrive in two
> different messages
Great Bart
This works fine for me albeit with some defensive overkill
{
...
:0wc:uudeview.lock
| /usr/bin/uudeview -i +a -p /home/eric/ -e .html -e .txt -e .001 -
:0w:uudeview2.lock
| /usr/bin/uudeview -i -p /someplace -e .html -e .txt -e .001 -
:0
| for i in /_/*.zip;do unzip -f -d /else $i;done
}
Muses:
Now if only I could insert the date into the filename ...
Eric