From patchwork Wed Dec 21 11:16:33 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Thadeu Lima de Souza Cascardo X-Patchwork-Id: 707738 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from huckleberry.canonical.com (huckleberry.canonical.com [91.189.94.19]) by ozlabs.org (Postfix) with ESMTP id 3tkBtt4scJz9t0H; Wed, 21 Dec 2016 22:16:54 +1100 (AEDT) Received: from localhost ([127.0.0.1] helo=huckleberry.canonical.com) by huckleberry.canonical.com with esmtp (Exim 4.76) (envelope-from ) id 1cJet4-0004tE-3u; Wed, 21 Dec 2016 11:16:46 +0000 Received: from youngberry.canonical.com ([91.189.89.112]) by huckleberry.canonical.com with esmtp (Exim 4.76) (envelope-from ) id 1cJesy-0004rp-Ii for kernel-team@lists.ubuntu.com; Wed, 21 Dec 2016 11:16:40 +0000 Received: from 1.general.cascardo.us.vpn ([10.172.70.58] helo=localhost.localdomain) by youngberry.canonical.com with esmtpsa (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.76) (envelope-from ) id 1cJesx-00022O-Pd for kernel-team@lists.ubuntu.com; Wed, 21 Dec 2016 11:16:40 +0000 From: Thadeu Lima de Souza Cascardo To: kernel-team@lists.ubuntu.com Subject: [PATCH] UBUNTU: [Debian] consider renames in gen-auto-reconstruct Date: Wed, 21 Dec 2016 09:16:33 -0200 Message-Id: <20161221111633.29432-1-cascardo@canonical.com> X-Mailer: git-send-email 2.9.3 X-BeenThere: kernel-team@lists.ubuntu.com X-Mailman-Version: 2.1.14 Precedence: list List-Id: Kernel team discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: kernel-team-bounces@lists.ubuntu.com Sender: kernel-team-bounces@lists.ubuntu.com Recent git versions have changed the rename detection to default when using git-diff. Previous behavior would allow the reconstruct script to remove the renamed files, which are added in the diff, but not removed. Using --no-renames option will revert to the previous behavior when using those recent git versions. Signed-off-by: Thadeu Lima de Souza Cascardo --- debian/scripts/misc/gen-auto-reconstruct | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/debian/scripts/misc/gen-auto-reconstruct b/debian/scripts/misc/gen-auto-reconstruct index 83c0428..a76e341 100755 --- a/debian/scripts/misc/gen-auto-reconstruct +++ b/debian/scripts/misc/gen-auto-reconstruct @@ -26,7 +26,7 @@ fi ( # Identify all new symlinks since the proffered tag. echo "# Recreate any symlinks created since the orig." - git diff "$tag.." --raw | awk '(/^:000000 120000/ && $5 == "A") { print $NF }' | \ + git diff "$tag.." --raw --no-renames | awk '(/^:000000 120000/ && $5 == "A") { print $NF }' | \ while read name do link=$( readlink "$name" ) @@ -36,7 +36,7 @@ fi # Identify all removed files since the proffered tag. echo "# Remove any files deleted from the orig." - git diff "$tag.." --raw | awk '(/^:/ && $5 == "D") { print $NF }' | \ + git diff "$tag.." --raw --no-renames | awk '(/^:/ && $5 == "D") { print $NF }' | \ while read name do echo "rm -f '$name'" @@ -49,7 +49,7 @@ fi ( # Identify all new symlinks since the proffered tag. echo "# Ignore any symlinks created since the orig which are rebuilt by reconstruct." - git diff "$tag.." --raw | awk '(/^:000000 120000/ && $5 == "A") { print $NF }' | \ + git diff "$tag.." --raw --no-renames | awk '(/^:000000 120000/ && $5 == "A") { print $NF }' | \ while read name do echo "extend-diff-ignore=$name"