9fans - fans of the OS Plan 9 from Bell Labs
 help / color / mirror / Atom feed
* [9fans] processing mail bodies
@ 2009-02-05 15:22 Steve Simon
  2009-02-05 15:26 ` erik quanstrom
  0 siblings, 1 reply; 2+ messages in thread
From: Steve Simon @ 2009-02-05 15:22 UTC (permalink / raw)
  To: 9fans

> i considered adding code to upas to at least
> strip pgp nonesense from message bodies.  but this
> would require upas to know things about what
> message bodies look like after mime is done with
> them.

FWIW I have several sources of mail which have large, unnecessary disclaimers,
adverts, signatures etc on them. I have a serise of test in /mail/box/steve/pipeto
along the lines of:

	if (grep -s 'Forum Subscription New Topic Notification' $D/subject){
		bin/powerboard $D | $BIN/deliver $RECIP $D/from $MBOX
		exit 0
	}

This runs /mail/box/steve/bin/XXX which contains sed scripts to
remove the rubbish. In this case (powerboard), I only receive a link
to the relevant bullitin board message, the script uses hget to pull
down the actual text.

-Steve



^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [9fans] processing mail bodies
  2009-02-05 15:22 [9fans] processing mail bodies Steve Simon
@ 2009-02-05 15:26 ` erik quanstrom
  0 siblings, 0 replies; 2+ messages in thread
From: erik quanstrom @ 2009-02-05 15:26 UTC (permalink / raw)
  To: 9fans

> FWIW I have several sources of mail which have large, unnecessary disclaimers,
> adverts, signatures etc on them. I have a serise of test in /mail/box/steve/pipeto
> along the lines of:
>
> 	if (grep -s 'Forum Subscription New Topic Notification' $D/subject){
> 		bin/powerboard $D | $BIN/deliver $RECIP $D/from $MBOX
> 		exit 0
> 	}
>
> This runs /mail/box/steve/bin/XXX which contains sed scripts to
> remove the rubbish. In this case (powerboard), I only receive a link
> to the relevant bullitin board message, the script uses hget to pull
> down the actual text.

might it be better for ned or Mail to do this?

- erik




^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2009-02-05 15:26 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-02-05 15:22 [9fans] processing mail bodies Steve Simon
2009-02-05 15:26 ` erik quanstrom

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).