But the [email protected] header only appears because it is a CC. This may not be consistent and itās certainly not obvious or convenient to filter on.
Perhaps Nanog will meet us halfway, and put right in the subject line āNANOG promotional emailā or something like that. Seriously. Or just let people subscribe toe [email protected] if they want those things. -mel via cell > On Nov 28, 2025, at 11:10āÆAM, Roman Tatarnikov via NANOG > <[email protected]> wrote: > > Ah, the power of `procmail`: > > PROCDIR=$HOME/.config/procmail > > :0 > * ^List-Id: .*\<([a-z0-9-]+\.)?arin\.net\> > { > SWITCHRC=$PROCDIR/arin.list > } > > :0 > * ^List-Id: (North American Network Operators > Group|.*\<(.+\.)?nanog\.org\>) > { > SWITCHRC=$PROCDIR/nang.list > } > > # vim: set filetype=procmail: > > Not many know about `INCLUDERC` and `SWITCHRC` directives in `procmail`. But > hopefully you got the idea. And it will help you break-down `procmail` config > into multiple ones and group filters based on categories. > > Didn't knew about Google Apps Script. Thanks Tom. Gives me something to look > into. > > And happy holidays everyone. > > On Fri, Nov 28, 2025 at 01:03:52PM -0500, Tom Beecher via NANOG wrote: >>> Thatās great news, Tom! Perhaps youāll share your filter for dropping >>> NANOG promotional emails? And no fair using ChatGPT :) >> >> >> In my Google Apps Script that I use for header based filtering, I would >> just do this: >> >> ... >> // NANOG Newsletters >> var from_h = message.getHeader("From"); >> var reply-to_h = message.getHeader("Reply-To"); >> if ( (from_h.includes('[email protected]') && >> reply-to_h.includes('[email protected]')) { >> >> message.getThread().addLabel(GmailApp.getUserLabelByName("NANOG-Promo")); >> message.getThread().moveToArchive(); >> } >> ... >> >> In a real mail client this is easier, but same idea. > > -- > Roman V Tatarnikov | https://linkedin.com/in/rtatarnikov > _______________________________________________ > NANOG mailing list > https://lists.nanog.org/archives/list/[email protected]/message/NKZLP3XSIEPUYAKE2CQIKB4O5PZXDTHQ/ > <signature.asc> _______________________________________________ NANOG mailing list https://lists.nanog.org/archives/list/[email protected]/message/HEA6EIJJYJNUAHAARJUXIWR4YJORKVOC/
