]> git.proxmox.com Git - mirror_ubuntu-zesty-kernel.git/commitdiff
UBUNTU: [Debian] consider renames in gen-auto-reconstruct
authorThadeu Lima de Souza Cascardo <cascardo@canonical.com>
Wed, 21 Dec 2016 11:16:33 +0000 (09:16 -0200)
committerAndy Whitcroft <apw@canonical.com>
Mon, 13 Mar 2017 18:32:05 +0000 (18:32 +0000)
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 <cascardo@canonical.com>
Acked-by: Tim Gardner <tim.gardner@canonical.com>
Signed-off-by: Luis Henriques <luis.henriques@canonical.com>
debian/scripts/misc/gen-auto-reconstruct

index 83c0428cd5a8f8db0f2ce3319c50dacf2f2dcc6e..a76e341a5e9828eb5b7d53ac4b2d81cf69bba4af 100755 (executable)
@@ -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"