From mboxrd@z Thu Jan 1 00:00:00 1970 Received: by 10.204.134.218 with SMTP id k26cs75673bkt; Thu, 10 Jun 2010 09:08:18 -0700 (PDT) Received: by 10.231.148.143 with SMTP id p15mr387427ibv.15.1276186096868; Thu, 10 Jun 2010 09:08:16 -0700 (PDT) Return-Path: Received: from rubyforge.org (rubyforge.org [205.234.109.19]) by mx.google.com with ESMTP id e10si266401ibb.63.2010.06.10.09.08.16; Thu, 10 Jun 2010 09:08:16 -0700 (PDT) Received-SPF: pass (google.com: domain of sup-talk-bounces@rubyforge.org designates 205.234.109.19 as permitted sender) client-ip=205.234.109.19; Authentication-Results: mx.google.com; spf=pass (google.com: domain of sup-talk-bounces@rubyforge.org designates 205.234.109.19 as permitted sender) smtp.mail=sup-talk-bounces@rubyforge.org Received: from rubyforge.org (rubyforge.org [127.0.0.1]) by rubyforge.org (Postfix) with ESMTP id 1D2AA1858394; Thu, 10 Jun 2010 12:08:16 -0400 (EDT) Received: from sam.mediasupervision.de (sam.mediasupervision.de [80.152.3.104]) by rubyforge.org (Postfix) with ESMTP id 1EA35185836B for ; Thu, 10 Jun 2010 11:52:30 -0400 (EDT) Received: from localhost (localhost [127.0.0.1]) by sam.mediasupervision.de (Postfix) with ESMTP id 6A8464860A4; Thu, 10 Jun 2010 17:52:25 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at sam.mediasupervision.de Received: from sam.mediasupervision.de ([127.0.0.1]) by localhost (sam.mediasupervision.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id VCffcSSOKxLc; Thu, 10 Jun 2010 17:52:25 +0200 (CEST) Received: by sam.mediasupervision.de (Postfix, from userid 1000) id 427A54860A6; Thu, 10 Jun 2010 17:52:25 +0200 (CEST) From: Gregor Hoffleit To: Eric Sherman In-reply-to: <1275997525-sup-9347@changeling.local> References: <1275850632-sup-6402@ubuntu.ubuntu-domain> <1275884981-sup-4509@roughage.com.au> <1275973780-sup-5206@ubuntu.ubuntu-domain> <1275997525-sup-9347@changeling.local> Date: Thu, 10 Jun 2010 17:52:25 +0200 Message-Id: <1276184688-sup-7287@sam.mediasupervision.de> User-Agent: Sup/git Cc: sup-talk Subject: Re: [sup-talk] choosing signatures X-BeenThere: sup-talk@rubyforge.org X-Mailman-Version: 2.1.12 Precedence: list List-Id: User & developer discussion of Sup List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: sup-talk-bounces@rubyforge.org Errors-To: sup-talk-bounces@rubyforge.org Eric, at first, that looks like a duplication of code. Could you elaborate why you use both of these hooks? Gregor * Eric Sherman [Di Jun 08 13:57:54 +0200 2010] > Excerpts from Daniel Goldin's message of Tue Jun 08 01:16:25 -0400 2010: > > Thanks so much, works like a charm. But is there a way to change the > > "From:" and "In-reply-to:" and "Reply-to:" headers without having to add > > the config option ":ask_for_from: true"? > > You may use the before-edit and reply-from hooks. Here are scrubbed > versions of mine: > > before-edit.rb: > if header["To"] =~ /megacorp|ultramegacorp|alternacorp|minicorp|othercorp/ > header["From"] = "me " > elsif header["To"] =~ /somelist|alternalist|otherlist/ > header["From"] = "me " > end > header["Bcc"] = header["From"] > > reply-from.rb: > val = case [message.recipient_email, message.to, message.cc, message.from].flatten.to_s > when /megacorp|ultramegacorp|alternacorp|minicorp|othercorp/ then "me " > when /personal.org/ then "me " > when /nerdylistemail.org|somelist|alternalist|otherlist/ then "me " > when /newemail/ then "me " > when /oldemail/ then "me " > end > Person.from_address val _______________________________________________ sup-talk mailing list sup-talk@rubyforge.org http://rubyforge.org/mailman/listinfo/sup-talk