Anton Aylward wrote:
On 13/06/2020 14:40, Per Jessen wrote:
David C. Rankin wrote:
Trivially, you can dump the To:/From: From:/To: address from an mbox file with:
awk '/^From:/ || /^To:/' mboxfile
awk is overkill :-)
Indeed. Awk, perl, python or ruby or ny other such that can habndle REs are only of use if you are also going to process any found addresses.
egrep '^(From|To):' mboxfile
At the very least I'd add the following space :-) Adding the RE to recognise an address isn't exactly difficult either. You might want' eventually, to refine it to restrict the domains it can handle and filter though FGREP using a file of spam addresses.
The only use I can think of for using 'formail' is in the syndromic case where there is a line in the body of the message that meets the RE.
Using formail would probably be really useful to fold continued lines into one (-c). -- Per Jessen, Zürich (15.8°C) http://www.cloudsuisse.com/ - your owncloud, hosted in Switzerland. -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse+owner@opensuse.org