From patchwork Tue Oct 16 07:39:21 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Rasmus Villemoes X-Patchwork-Id: 10643189 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 68B45925 for ; Tue, 16 Oct 2018 07:39:36 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 52D3329858 for ; Tue, 16 Oct 2018 07:39:36 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 46A1829862; Tue, 16 Oct 2018 07:39:36 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-8.0 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,MAILING_LIST_MULTI,RCVD_IN_DNSWL_HI autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id E65DE29858 for ; Tue, 16 Oct 2018 07:39:35 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726982AbeJPP2l (ORCPT ); Tue, 16 Oct 2018 11:28:41 -0400 Received: from mail-ed1-f66.google.com ([209.85.208.66]:37284 "EHLO mail-ed1-f66.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726649AbeJPP2l (ORCPT ); Tue, 16 Oct 2018 11:28:41 -0400 Received: by mail-ed1-f66.google.com with SMTP id c22-v6so20313741edc.4 for ; Tue, 16 Oct 2018 00:39:33 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=rasmusvillemoes.dk; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=8gbRzLEm5Vnu9GUpKJ6505F5LBVI1wi7wTqzsEOyec4=; b=dIpVPNXD79wePMjGnAUFJkvFNaWy3q/t7wvRWLxvc7f6JObe4JxTGFVNP2vw5GHt7B L8jTI4K+ocdo9qZMWc81Psr5hZPRQJ3z2vivGV8fDcJ+HcsBuw6Yv6ic9N3H07UZATp0 ccHYOHCHzoWth3NMQLCrvU4cllXdJnShQByxk= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=8gbRzLEm5Vnu9GUpKJ6505F5LBVI1wi7wTqzsEOyec4=; b=WX8uvjvBXJzJudoT5G35OEgjZCqyoOaTMQ9FgNtVwfnAXX+LXE0og5tijAJschHSKC qVbXLNZ5+Rs4rOjoJeOa64fs8H9CFAm+/dTIJLgu+aZW5tYw0Fr8+3Cha0CJsLjYA5Su jpAEjrBXXvMe9VuyNr7wUsguEPcT7ULi4b7C1LWsocGsXY0FB4dqatPOzqNXbKpTWuhQ m3Jpxyv6tGwyW9EWvdQOOBwJ2ws97r5nvS12+DhP2KaDr2hyZp4l62u+6TcxybVY9P3j OjaynMEXiF2rSzSav4jpmHIkEiiftx6sp7ZjlXmWyKtAB1R4/uNngHrFEG0pdGxtzPFd hI2g== X-Gm-Message-State: ABuFfoiViEcfP+6rYPOiwkWM1yaYlF+nX4ThYzpTEiqgb23Ow5Z2bQUy n5ZcDzK50PSHxSo1I8WJEgO13nvjVrI= X-Google-Smtp-Source: ACcGV63/cXZHoN1KsJHaK8s3AwEo1RFw6LrktmD7ChuA+UMtLDKnMhxbZ83N49C0zWmAT28zIeSXew== X-Received: by 2002:a17:906:c19:: with SMTP id s25-v6mr15401777ejf.140.1539675572604; Tue, 16 Oct 2018 00:39:32 -0700 (PDT) Received: from prevas-ravi.vestasvisitor.net ([193.47.71.171]) by smtp.gmail.com with ESMTPSA id q18-v6sm2774661ejr.8.2018.10.16.00.39.31 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Tue, 16 Oct 2018 00:39:32 -0700 (PDT) From: Rasmus Villemoes To: git@vger.kernel.org Cc: Junio C Hamano , Rasmus Villemoes Subject: [PATCH v2 1/3] Documentation/git-send-email.txt: style fixes Date: Tue, 16 Oct 2018 09:39:21 +0200 Message-Id: <20181016073923.28134-2-rv@rasmusvillemoes.dk> X-Mailer: git-send-email 2.19.1.6.gbde171bbf5 In-Reply-To: <20181016073923.28134-1-rv@rasmusvillemoes.dk> References: <20181010111351.5045-1-rv@rasmusvillemoes.dk> <20181016073923.28134-1-rv@rasmusvillemoes.dk> MIME-Version: 1.0 Sender: git-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: git@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP For consistency, add full stops in a few places and outdent a line by one space. Signed-off-by: Rasmus Villemoes --- Documentation/git-send-email.txt | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/Documentation/git-send-email.txt b/Documentation/git-send-email.txt index 465a4ecbed..ea6ea512fe 100644 --- a/Documentation/git-send-email.txt +++ b/Documentation/git-send-email.txt @@ -321,16 +321,16 @@ Automating auto-cc of: + -- -- 'author' will avoid including the patch author -- 'self' will avoid including the sender +- 'author' will avoid including the patch author. +- 'self' will avoid including the sender. - 'cc' will avoid including anyone mentioned in Cc lines in the patch header except for self (use 'self' for that). - 'bodycc' will avoid including anyone mentioned in Cc lines in the patch body (commit message) except for self (use 'self' for that). - 'sob' will avoid including anyone mentioned in Signed-off-by lines except - for self (use 'self' for that). + for self (use 'self' for that). - 'cccmd' will avoid running the --cc-cmd. -- 'body' is equivalent to 'sob' + 'bodycc' +- 'body' is equivalent to 'sob' + 'bodycc'. - 'all' will suppress all auto cc values. -- + From patchwork Tue Oct 16 07:39:22 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Rasmus Villemoes X-Patchwork-Id: 10643191 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 8117413AD for ; Tue, 16 Oct 2018 07:39:45 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 6A79529858 for ; Tue, 16 Oct 2018 07:39:45 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 5E96729862; Tue, 16 Oct 2018 07:39:45 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-8.0 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,MAILING_LIST_MULTI,RCVD_IN_DNSWL_HI autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id E236B29858 for ; Tue, 16 Oct 2018 07:39:44 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726994AbeJPP2v (ORCPT ); Tue, 16 Oct 2018 11:28:51 -0400 Received: from mail-ed1-f68.google.com ([209.85.208.68]:39330 "EHLO mail-ed1-f68.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726649AbeJPP2u (ORCPT ); Tue, 16 Oct 2018 11:28:50 -0400 Received: by mail-ed1-f68.google.com with SMTP id d15-v6so20304523edq.6 for ; Tue, 16 Oct 2018 00:39:42 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=rasmusvillemoes.dk; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=pndbho1JTYlAgSTBbPgtKLpVz2ohrCt15jtlqQq/yaQ=; b=KVTdRQuzB7bd7lSHJv5RXZVNyY16cbIHI0BzKMLylTU8bTM9UvUatS0JNbkts8OlhH gjocQBTywrkNxbAOsVmCMpcK5/nG+MY/QEk8Da5Y7n9OwDO8udgYufdXVsybuCujjulM jaiDK/i9XwL6XZc1Egqv88Z5FDz1AgD3mWcqg= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=pndbho1JTYlAgSTBbPgtKLpVz2ohrCt15jtlqQq/yaQ=; b=hnFWQMYlkb5KVsTIDGTrdZ3nK7mY/YEGpByQ6MIqEZkRVWWMtabfyo9h6+D8uIyRs6 3nbouiaKIm+uSU8oJOsgyB9MyMnwTokAfbh2ETmHlbtDMQDXnHcn6VeybHZfIX74Eq42 lkw/7W4pjIwLRx4MO2jke5Mfa1SVquINBvGyZ0Lr/iX+TbhoDewaHA0+sKCj4jNZTgOb xsi/EBfFwNtxADQGCHAriZpvZF+E12HwRFYQ7YDWogjfWYJeG3+GjARd6APx+3fmkKEW AhisXss1sLwoegHePIDK0hs/g4fYG8XcGhfrQEl6aHXfd2O1o+3OOv11lkwm4QMDs9oT 3Eog== X-Gm-Message-State: ABuFfoiWMRR4bZTB59vCW/cBqZ+5m4aldddaZJN4hr5dHo4LvOp3YnDl BzJNIE4sGLDBuf8RPXL3hc/y7Ynthk0= X-Google-Smtp-Source: ACcGV62bGqsodn8ASXI06PN97dCrCkGVU64XcVpPwuK/npYKorY47yP4qDClOSb8XHEItYApl5KGjg== X-Received: by 2002:a17:906:755d:: with SMTP id a29-v6mr21904595ejn.84.1539675581476; Tue, 16 Oct 2018 00:39:41 -0700 (PDT) Received: from prevas-ravi.vestasvisitor.net ([193.47.71.171]) by smtp.gmail.com with ESMTPSA id q18-v6sm2774661ejr.8.2018.10.16.00.39.40 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Tue, 16 Oct 2018 00:39:40 -0700 (PDT) From: Rasmus Villemoes To: git@vger.kernel.org Cc: Junio C Hamano , Rasmus Villemoes Subject: [PATCH v2 2/3] send-email: only consider lines containing @ or <> for automatic Cc'ing Date: Tue, 16 Oct 2018 09:39:22 +0200 Message-Id: <20181016073923.28134-3-rv@rasmusvillemoes.dk> X-Mailer: git-send-email 2.19.1.6.gbde171bbf5 In-Reply-To: <20181016073923.28134-1-rv@rasmusvillemoes.dk> References: <20181010111351.5045-1-rv@rasmusvillemoes.dk> <20181016073923.28134-1-rv@rasmusvillemoes.dk> MIME-Version: 1.0 Sender: git-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: git@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP While the address sanitizations routines do accept local addresses, that is almost never what is meant in a Cc or Signed-off-by trailer. Looking through all the signed-off-by lines in the linux kernel tree without a @, there are mostly two patterns: Either just a full name, or a full name followed by (i.e., with the word at instead of a @), and minor variations. For cc lines, the same patterns appear, along with lots of "cc stable" variations that do not actually name stable@vger.kernel.org Cc: stable # introduced pre-git times cc: stable.kernel.org In the cases, one gets a chance to interactively fix it. But when there is no <> pair, it seems we end up just using the first word as a (local) address. As the number of cases where a local address really was meant is likely (and anecdotally) quite small compared to the number of cases where we end up cc'ing a garbage address, insist on at least a @ or a <> pair being present. This is also preparation for the next patch, where we are likely to encounter even more non-addresses in -by lines, such as Reported-by: Coverity Patch-generated-by: Coccinelle Signed-off-by: Rasmus Villemoes --- git-send-email.perl | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/git-send-email.perl b/git-send-email.perl index 2be5dac337..1916159d2a 100755 --- a/git-send-email.perl +++ b/git-send-email.perl @@ -1694,6 +1694,11 @@ sub process_file { next if $suppress_cc{'sob'} and $what =~ /Signed-off-by/i; next if $suppress_cc{'bodycc'} and $what =~ /Cc/i; } + if ($c !~ /.+@.+|<.+>/) { + printf("(body) Ignoring %s from line '%s'\n", + $what, $_) unless $quiet; + next; + } push @cc, $c; printf(__("(body) Adding cc: %s from line '%s'\n"), $c, $_) unless $quiet; From patchwork Tue Oct 16 07:39:23 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Rasmus Villemoes X-Patchwork-Id: 10643193 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 000F613AD for ; Tue, 16 Oct 2018 07:39:50 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id DA2DB29858 for ; Tue, 16 Oct 2018 07:39:50 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id C95E329862; Tue, 16 Oct 2018 07:39:50 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-8.0 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,MAILING_LIST_MULTI,RCVD_IN_DNSWL_HI autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 317EB29858 for ; Tue, 16 Oct 2018 07:39:50 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727087AbeJPP2z (ORCPT ); Tue, 16 Oct 2018 11:28:55 -0400 Received: from mail-ed1-f65.google.com ([209.85.208.65]:43327 "EHLO mail-ed1-f65.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727015AbeJPP2y (ORCPT ); Tue, 16 Oct 2018 11:28:54 -0400 Received: by mail-ed1-f65.google.com with SMTP id y20-v6so20297718eds.10 for ; Tue, 16 Oct 2018 00:39:45 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=rasmusvillemoes.dk; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=VqzXTukhLqC813DsnUwOg5tYq5g4s4ggOPE98hqHr2c=; b=KITQTfrzdcspbKuvIrpvC9vMq4VUYuJ4uqQKs7oJUCaUwOMzTZiLwEuIkMp8qef1ER TUrpbEydLAZcvtR/K7l0vIdpTCM+zZeeIsD0XuZUq6gTFth9+BaV5MxonhwFZiSOLAuN CqsEJePoGH9WnJPn4C9gJx4jqA7pa2nUTTfF4= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=VqzXTukhLqC813DsnUwOg5tYq5g4s4ggOPE98hqHr2c=; b=j2CV2ji9k1W4GkDClUki5hnERC+xvRgGBVmFk4N7xFl+jlI6zJi+HddoM/TmJf8jVK B2kMovLZHXP7A9ns0s3SNDTRMy1Ees2wQSWNpsRrv2RsYcV3cG0UCLZYlBlmZjhM8Te8 n9p/n82OIRLqntdR3extlv89Qo/1YHfTvNVBQf5myJVILgaUgNHtkUjKNHsi93FoJ4Aa N6ROR0lNbqFAitn6KBYHvyKBiknAdLlhh/9JStvMhWewq4KGadex+s03/UXVQ/OoKasq Eq91ehlaBB9yPCryyQGoB3HrjOJlIe2xXnnmSfZFZkEhrCy6acUU/2ch1o9+szhmIr2V sCsQ== X-Gm-Message-State: ABuFfoigtoLcbtUervanRgVTs9C/GI5HCeCyWldmOBdyX3gJdxggrMIa zZcz82ULyA3UqZ2DzJlSgYPi+5S8XOE= X-Google-Smtp-Source: ACcGV638QiEHd2JjoQvotNmuiQWJsOdBXq2TzGoYNecIvlrlJ8xor+PIA5Rve2tt+/i2T/PNiN6Cbw== X-Received: by 2002:a50:eb97:: with SMTP id y23-v6mr28397652edr.38.1539675584812; Tue, 16 Oct 2018 00:39:44 -0700 (PDT) Received: from prevas-ravi.vestasvisitor.net ([193.47.71.171]) by smtp.gmail.com with ESMTPSA id q18-v6sm2774661ejr.8.2018.10.16.00.39.43 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Tue, 16 Oct 2018 00:39:44 -0700 (PDT) From: Rasmus Villemoes To: git@vger.kernel.org Cc: Junio C Hamano , Rasmus Villemoes , Joe Perches Subject: [PATCH v2 3/3] send-email: also pick up cc addresses from -by trailers Date: Tue, 16 Oct 2018 09:39:23 +0200 Message-Id: <20181016073923.28134-4-rv@rasmusvillemoes.dk> X-Mailer: git-send-email 2.19.1.6.gbde171bbf5 In-Reply-To: <20181016073923.28134-1-rv@rasmusvillemoes.dk> References: <20181010111351.5045-1-rv@rasmusvillemoes.dk> <20181016073923.28134-1-rv@rasmusvillemoes.dk> MIME-Version: 1.0 Sender: git-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: git@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP When rerolling a patch series, including various Reviewed-by etc. that may have come in, it is quite convenient to have git-send-email automatically cc those people. So pick up any *-by lines, with a new suppression category 'misc-by', but special-case Signed-off-by, since that already has its own suppression category. It seems natural to make 'misc-by' implied by 'body'. Based-on-patch-by: Joe Perches Signed-off-by: Rasmus Villemoes --- Documentation/git-send-email.txt | 5 ++++- git-send-email.perl | 19 ++++++++++++------- 2 files changed, 16 insertions(+), 8 deletions(-) diff --git a/Documentation/git-send-email.txt b/Documentation/git-send-email.txt index ea6ea512fe..f6010ac68b 100644 --- a/Documentation/git-send-email.txt +++ b/Documentation/git-send-email.txt @@ -329,8 +329,11 @@ Automating patch body (commit message) except for self (use 'self' for that). - 'sob' will avoid including anyone mentioned in Signed-off-by lines except for self (use 'self' for that). +- 'misc-by' will avoid including anyone mentioned in Acked-by, + Reviewed-by, Tested-by and other "-by" lines in the patch body, + except Signed-off-by (use 'sob' for that). - 'cccmd' will avoid running the --cc-cmd. -- 'body' is equivalent to 'sob' + 'bodycc'. +- 'body' is equivalent to 'sob' + 'bodycc' + 'misc-by'. - 'all' will suppress all auto cc values. -- + diff --git a/git-send-email.perl b/git-send-email.perl index 1916159d2a..58c6aa9d0e 100755 --- a/git-send-email.perl +++ b/git-send-email.perl @@ -94,7 +94,7 @@ sub usage { --identity * Use the sendemail. options. --to-cmd * Email To: via ` \$patch_path` --cc-cmd * Email Cc: via ` \$patch_path` - --suppress-cc * author, self, sob, cc, cccmd, body, bodycc, all. + --suppress-cc * author, self, sob, cc, cccmd, body, bodycc, misc-by, all. --[no-]cc-cover * Email Cc: addresses in the cover letter. --[no-]to-cover * Email To: addresses in the cover letter. --[no-]signed-off-by-cc * Send to Signed-off-by: addresses. Default on. @@ -454,13 +454,13 @@ sub read_config { if (@suppress_cc) { foreach my $entry (@suppress_cc) { die sprintf(__("Unknown --suppress-cc field: '%s'\n"), $entry) - unless $entry =~ /^(?:all|cccmd|cc|author|self|sob|body|bodycc)$/; + unless $entry =~ /^(?:all|cccmd|cc|author|self|sob|body|bodycc|misc-by)$/; $suppress_cc{$entry} = 1; } } if ($suppress_cc{'all'}) { - foreach my $entry (qw (cccmd cc author self sob body bodycc)) { + foreach my $entry (qw (cccmd cc author self sob body bodycc misc-by)) { $suppress_cc{$entry} = 1; } delete $suppress_cc{'all'}; @@ -471,7 +471,7 @@ sub read_config { $suppress_cc{'sob'} = !$signed_off_by_cc if defined $signed_off_by_cc; if ($suppress_cc{'body'}) { - foreach my $entry (qw (sob bodycc)) { + foreach my $entry (qw (sob bodycc misc-by)) { $suppress_cc{$entry} = 1; } delete $suppress_cc{'body'}; @@ -1681,7 +1681,7 @@ sub process_file { # Now parse the message body while(<$fh>) { $message .= $_; - if (/^(Signed-off-by|Cc): (.*)/i) { + if (/^([a-z-]*-by|Cc): (.*)/i) { chomp; my ($what, $c) = ($1, $2); # strip garbage for the address we'll use: @@ -1691,8 +1691,13 @@ sub process_file { if ($sc eq $sender) { next if ($suppress_cc{'self'}); } else { - next if $suppress_cc{'sob'} and $what =~ /Signed-off-by/i; - next if $suppress_cc{'bodycc'} and $what =~ /Cc/i; + if ($what =~ /^Signed-off-by$/i) { + next if $suppress_cc{'sob'}; + } elsif ($what =~ /-by$/i) { + next if $suppress_cc{'misc-by'}; + } elsif ($what =~ /Cc/i) { + next if $suppress_cc{'bodycc'}; + } } if ($c !~ /.+@.+|<.+>/) { printf("(body) Ignoring %s from line '%s'\n",