Archive of RubyForge sup-talk mailing list
 help / color / mirror / Atom feed
* [sup-talk] Multiple email accounts
@ 2009-05-23 23:32 Edward Z. Yang
  2009-05-23 23:57 ` Iain
  0 siblings, 1 reply; 5+ messages in thread
From: Edward Z. Yang @ 2009-05-23 23:32 UTC (permalink / raw)


Hello all,

Does Sup have any built-in support for multiple sending email accounts, i.e.
using the source to determine what the "From" header should be, and swapping
SMTP servers accordingly?

Cheers,
Edward


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

* [sup-talk] Multiple email accounts
  2009-05-23 23:32 [sup-talk] Multiple email accounts Edward Z. Yang
@ 2009-05-23 23:57 ` Iain
  2009-05-25 18:18   ` Edward Z. Yang
  0 siblings, 1 reply; 5+ messages in thread
From: Iain @ 2009-05-23 23:57 UTC (permalink / raw)


> Does Sup have any built-in support for multiple sending email accounts, i.e.
> using the source to determine what the "From" header should be, and swapping
> SMTP servers accordingly?

Yes. See
<http://sup.rubyforge.org/wiki/wiki.pl?MultipleAccountsAndReply> and
<http://sup.rubyforge.org/wiki/wiki.pl?Msmtp>.

Cheers,
~Iain


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

* [sup-talk] Multiple email accounts
  2009-05-23 23:57 ` Iain
@ 2009-05-25 18:18   ` Edward Z. Yang
  2009-05-27 16:22     ` William Morgan
  0 siblings, 1 reply; 5+ messages in thread
From: Edward Z. Yang @ 2009-05-25 18:18 UTC (permalink / raw)


Excerpts from rhomunuq+ml_sup's message of Sat May 23 19:57:36 -0400 2009:
> Yes. See
> <http://sup.rubyforge.org/wiki/wiki.pl?MultipleAccountsAndReply> and
> <http://sup.rubyforge.org/wiki/wiki.pl?Msmtp>.

Great, that's 99% of what I need. The last 1% is, can Sup auto-detect
what From line to send based on the source of the message, if the
To: header is not intact? (This is commonly the case for mailing lists.

Cheers,
Edward


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

* [sup-talk] Multiple email accounts
  2009-05-25 18:18   ` Edward Z. Yang
@ 2009-05-27 16:22     ` William Morgan
  2009-05-27 18:51       ` Marcus Williams
  0 siblings, 1 reply; 5+ messages in thread
From: William Morgan @ 2009-05-27 16:22 UTC (permalink / raw)


Reformatted excerpts from Edward Z. Yang's message of 2009-05-25:
> Great, that's 99% of what I need. The last 1% is, can Sup auto-detect
> what From line to send based on the source of the message, if the To:
> header is not intact? (This is commonly the case for mailing lists.

You can use the reply-from hook to set it automatically however you
want. Try adding something like the following (completely untested!) to
~/.sup/hooks/reply-from.rb:

  case message.from.email
  when /sup-talk at rubyforge.org/i
    Person.from_address "Edward Z. Yang <ezy+i-love-sup at mit.edu>"
  end

If the hook returns nil, Sup does the default computation.
-- 
William <wmorgan-sup at masanjin.net>


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

* [sup-talk] Multiple email accounts
  2009-05-27 16:22     ` William Morgan
@ 2009-05-27 18:51       ` Marcus Williams
  0 siblings, 0 replies; 5+ messages in thread
From: Marcus Williams @ 2009-05-27 18:51 UTC (permalink / raw)


On 27.5.2009, William Morgan wrote:
> > Great, that's 99% of what I need. The last 1% is, can Sup auto-detect
> > what From line to send based on the source of the message, if the To:
> > header is not intact? (This is commonly the case for mailing lists.
> 
> You can use the reply-from hook to set it automatically however you
> want. Try adding something like the following (completely untested!) to
> ~/.sup/hooks/reply-from.rb:
[snip]

Note also that you might be able to do what you want with the regexen
options in config.yaml - so for instance Sup works out that I reply to
the sup talk mail list with marcus-sup at .... It uses the envelope-to
header to figure this out I seem to remember (coupled with the regexen
settings).

So under one of my accounts I have:

 :regexen:
   - marcus-.*(at)mydomain.com

(where (at) is replaced with @, and mydomain.com is replaced with the
obvious).

This make sup recognise all incoming emails to my email extensions
that all begin with "marcus-" and unlike the :alternative: settings
are used by sup to figure out what address to reply with. Works well
for all the mailing lists I'm using.

The only problem is they dont get used for sending new addresses (but
I recently sent an email about how I get around that).

HTH

Marcus


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

end of thread, other threads:[~2009-05-27 18:51 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-05-23 23:32 [sup-talk] Multiple email accounts Edward Z. Yang
2009-05-23 23:57 ` Iain
2009-05-25 18:18   ` Edward Z. Yang
2009-05-27 16:22     ` William Morgan
2009-05-27 18:51       ` Marcus Williams

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox