From mboxrd@z Thu Jan 1 00:00:00 1970 Received: by 10.42.240.136 with SMTP id la8cs154870icb; Thu, 10 Feb 2011 11:27:48 -0800 (PST) Received: by 10.91.196.3 with SMTP id y3mr3108776agp.205.1297366067529; Thu, 10 Feb 2011 11:27:47 -0800 (PST) Return-Path: Received: from rubyforge.org (rubyforge.org [205.234.109.19]) by mx.google.com with ESMTP id z19si718363vby.20.2011.02.10.11.27.47; Thu, 10 Feb 2011 11:27:47 -0800 (PST) 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 19EE41858363; Thu, 10 Feb 2011 14:27:47 -0500 (EST) Received: from plecavalier.com (thelittlecloset.ca [64.40.149.83]) by rubyforge.org (Postfix) with ESMTP id 014721858363 for ; Thu, 10 Feb 2011 14:19:52 -0500 (EST) Received: (qmail 12110 invoked from network); 10 Feb 2011 13:19:51 -0600 Received: from xplr-142-46-160-183.xplornet.com (HELO localhost) (142.46.160.183) by plecavalier.com with (DHE-RSA-AES128-SHA encrypted) SMTP; 10 Feb 2011 13:19:51 -0600 From: Philippe LeCavalier To: Mark Alexander In-reply-to: <1297357197-sup-5893@bloovis.org> References: <1297346751-sup-70@plc.intranet.plecavalier.com> <1297355619-sup-8657@bloovis.org> <1297356327-sup-9107@plc.intranet.plecavalier.com> <1297357197-sup-5893@bloovis.org> Date: Thu, 10 Feb 2011 14:19:49 -0500 Message-Id: <1297364797-sup-8388@plc.intranet.plecavalier.com> User-Agent: Sup/0.12.1 Cc: sup-talk@rubyforge.org Subject: Re: [sup-talk] best method for before-add-message.rb 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 Hi. I apologize in advance for the broken thread...Since I forgot a linebreak at the beginning of the body so everything got mangled upon exiting vim. I did my best to re-create the order. Excerpts from Mark Alexander's message of Thu Feb 10 12:00:17 -0500 2011: > Excerpts from Philippe LeCavalier's message of Thu Feb 10 11:52:53 -0500 2011: > > Hi Mark. > > Have you tried? > > > > case message.subj > > when /\[P4 SUBMIT/ > > message.add_label :p4 > > message.remove_label :inbox > > end > > No, I haven't tried remove_label. I did some testing and for some reason I cannot see, the above code automatically archives the msg without any obvious code telling sup to do so. If I: case message.from.email when /@plecavalier.com/ message.add_label :TEST message.add_label :TEST2 message.add_label :TEST3 end tests sent to myself are respectively labeled TEST TEST2 TEST3 but are also striped of the inbox label. Since this is exactly what I want this works for me but... -- Thanks, Phil _______________________________________________ sup-talk mailing list sup-talk@rubyforge.org http://rubyforge.org/mailman/listinfo/sup-talk