pg.ddx.io pgsql-general@postgresql.org mailing list archive
help / color / mirror / Atom feedProcmail recipe for new setup
6+ messages / 5 participants
[nested] [flat]
* Procmail recipe for new setup
@ 2017-11-20 22:10 Steve Litt <slitt@troubleshooters.com>
0 siblings, 3 replies; 6+ messages in thread
From: Steve Litt @ 2017-11-20 22:10 UTC (permalink / raw)
To: pgsql-general
Hi all,
The following procmail recipe works for me:
===========================================
:0:
* ^(To|Cc).*pgsql-general@postgresql.org
.Postgres/
===========================================
In the preceding, the slash at the end of the destination (.Postgres)
is because Procmail is inserting the mail into a maildir (the maildir
for my local Dovecot IMAP server). I use the (To|Cc) vocabulary instead
of something like a list-id email heading to accommodate those who for
some reason email me and copy the list, or email the list and copy me.
(To|Cc) seems to work under all conditions.
Any recipes based on [GENERAL] being in the subject have stopped
working because [GENERAL] is no longer in the subject.
SteveT
Steve Litt
November 2017 featured book: Troubleshooting: Just the Facts
http://www.troubleshooters.com/tjust
^ permalink raw reply [nested|flat] 6+ messages in thread
* Re: Procmail recipe for new setup
@ 2017-11-20 22:18 Rich Shepard <rshepard@appl-ecosys.com>
parent: Steve Litt <slitt@troubleshooters.com>
2 siblings, 1 reply; 6+ messages in thread
From: Rich Shepard @ 2017-11-20 22:18 UTC (permalink / raw)
To: pgsql-general
On Mon, 20 Nov 2017, Steve Litt wrote:
> The following procmail recipe works for me:
>
> ===========================================
> :0:
> * ^(To|Cc).*pgsql-general@postgresql.org
> .Postgres/
> ===========================================
Hi, Steve!
Here's an alternative recipe:
:0:
* ^TO_.*pgsql-general@(lists\.)?postgresql.org
POSTGRES
The TO_(with no space after it) captures CCs too, and the regex (lists\.)?
says accept 0 (zero) or 1 (one) of the lists prefix. I use mbox not maildir
so POSTGRES is the name of the file in ~/mail/.
Regards,
Rich
^ permalink raw reply [nested|flat] 6+ messages in thread
* Re: Procmail recipe for new setup
@ 2017-11-20 22:18 Joshua D. Drake <jd@commandprompt.com>
parent: Steve Litt <slitt@troubleshooters.com>
2 siblings, 0 replies; 6+ messages in thread
From: Joshua D. Drake @ 2017-11-20 22:18 UTC (permalink / raw)
To: pgsql-general@lists.postgresql.org
On 11/20/2017 02:10 PM, Steve Litt wrote:
> Hi all,
>
> The following procmail recipe works for me:
>
> ===========================================
> :0:
> * ^(To|Cc).*pgsql-general@postgresql.org
> .Postgres/
> ===========================================
You may want to use TO ... See here:
https://www.mhonarc.org/archive/html/procmail/1998-04/msg00093.html
Thanks,
JD
--
Command Prompt, Inc. || http://the.postgres.company/ || @cmdpromptinc
PostgreSQL Centered full stack support, consulting and development.
Advocate: @amplifypostgres || Learn: https://pgconf.org
***** Unless otherwise stated, opinions are my own. *****
^ permalink raw reply [nested|flat] 6+ messages in thread
* Re: Procmail recipe for new setup
@ 2017-11-20 22:21 Piotr Stefaniak <postgres@piotr-stefaniak.me>
parent: Steve Litt <slitt@troubleshooters.com>
2 siblings, 1 reply; 6+ messages in thread
From: Piotr Stefaniak @ 2017-11-20 22:21 UTC (permalink / raw)
To: Steve Litt <slitt@troubleshooters.com>; pgsql-general
On 2017-11-20 23:10, Steve Litt wrote:
> The following procmail recipe works for me:
I use this:
:0
* ^List-Id: \/.*
{
:0
* $MATCH ?? [<]+\/.*[^>]+
$MATCH/
:0
$MATCH/
}
^ permalink raw reply [nested|flat] 6+ messages in thread
* Re: Procmail recipe for new setup
@ 2017-11-20 22:38 Stephen Frost <sfrost@snowman.net>
parent: Piotr Stefaniak <postgres@piotr-stefaniak.me>
0 siblings, 0 replies; 6+ messages in thread
From: Stephen Frost @ 2017-11-20 22:38 UTC (permalink / raw)
To: Piotr Stefaniak <postgres@piotr-stefaniak.me>; +Cc: Steve Litt <slitt@troubleshooters.com>; pgsql-general
Greetings Piotr,
* Piotr Stefaniak (postgres@piotr-stefaniak.me) wrote:
> On 2017-11-20 23:10, Steve Litt wrote:
>
> > The following procmail recipe works for me:
>
> I use this:
>
> :0
> * ^List-Id: \/.*
> {
> :0
> * $MATCH ?? [<]+\/.*[^>]+
> $MATCH/
>
> :0
> $MATCH/
> }
I would caution against using this kind of expansion as it may allow
malicious attackers to generate all kinds of not-nice stuff in your mail
directories.
Thanks!
Stephen
Attachments:
signature.asc (application/pgp-signature, 818B) download
^ permalink raw reply [nested|flat] 6+ messages in thread
* Re: Procmail recipe for new setup
@ 2017-11-20 22:39 Stephen Frost <sfrost@snowman.net>
parent: Rich Shepard <rshepard@appl-ecosys.com>
0 siblings, 0 replies; 6+ messages in thread
From: Stephen Frost @ 2017-11-20 22:39 UTC (permalink / raw)
To: Rich Shepard <rshepard@appl-ecosys.com>; +Cc: pgsql-general
Greetings Rich, all,
* Rich Shepard (rshepard@appl-ecosys.com) wrote:
> On Mon, 20 Nov 2017, Steve Litt wrote:
>
> >The following procmail recipe works for me:
> >
> >===========================================
> >:0:
> >* ^(To|Cc).*pgsql-general@postgresql.org
> >.Postgres/
> >===========================================
>
> Hi, Steve!
>
> Here's an alternative recipe:
>
> :0:
> * ^TO_.*pgsql-general@(lists\.)?postgresql.org
> POSTGRES
>
> The TO_(with no space after it) captures CCs too, and the regex (lists\.)?
> says accept 0 (zero) or 1 (one) of the lists prefix. I use mbox not maildir
> so POSTGRES is the name of the file in ~/mail/.
Yes, this is a good recipe to use, particularly as we will be,
eventually, encouraging more use of the 'lists.postgresql.org'
subdomain in the future, and email is already being accepted for the
lists through it.
Thanks!
Stephen
Attachments:
signature.asc (application/pgp-signature, 818B) download
^ permalink raw reply [nested|flat] 6+ messages in thread
end of thread, other threads:[~2017-11-20 22:39 UTC | newest]
Thread overview: 6+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2017-11-20 22:10 Procmail recipe for new setup Steve Litt <slitt@troubleshooters.com>
2017-11-20 22:18 ` Rich Shepard <rshepard@appl-ecosys.com>
2017-11-20 22:39 ` Stephen Frost <sfrost@snowman.net>
2017-11-20 22:18 ` Joshua D. Drake <jd@commandprompt.com>
2017-11-20 22:21 ` Piotr Stefaniak <postgres@piotr-stefaniak.me>
2017-11-20 22:38 ` Stephen Frost <sfrost@snowman.net>
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox