All pastes #47747 Raw Edit

Stuff

public text v1 · immutable
#47747 ·published 2006-03-31 23:28 UTC
rendered paste body
diamond@fluff:~/pc(0)$ ls
headers.txt  procmailrc  run.sh
diamond@fluff:~/pc(0)$ cat run.sh
#!/bin/bash

cat procmailrc | sed -n 's/^\* \(.*\)/\1/p' | while read; do
grep -E "$REPLY" headers.txt &> /dev/null && echo "Matched by $REPLY"
done
diamond@fluff:~/pc(0)$ ./run.sh
Matched by ^List-Id.*mit.*.skynet.ie
Matched by ^List-Id.*compsoc.lists.skynet.ie
Matched by ^List-Id.*.skynet.ie