From fafc9c67bc9cf27f4624e9def9e9deafffdfc442 Mon Sep 17 00:00:00 2001 From: Ian Jackson Date: Mon, 19 Dec 2016 14:54:30 +0000 Subject: [PATCH 1/1] absurd/git: Do not fail to import a .dsc containing patches to .git/ (!) Signed-off-by: Ian Jackson --- absurd/git | 8 ++++++++ debian/changelog | 1 + 2 files changed, 9 insertions(+) diff --git a/absurd/git b/absurd/git index 7d3ff941..0f562b54 100755 --- a/absurd/git +++ b/absurd/git @@ -95,7 +95,15 @@ END printf "%s\n" "$omgwtf" >debian/patches/series printf "%s\n" "$patch" >>debian/patches/series +# Just in case some joker tries to patch .git/something +mv .git ../.git +set +e dpkg-source --before-build . +rc=$? +set -e +rm -rf .git +mv ../.git . +test $rc = 0 rm -f $omgwtf debian/patches/$omgwtf diff --git a/debian/changelog b/debian/changelog index e26c4de4..d4e18e63 100644 --- a/debian/changelog +++ b/debian/changelog @@ -23,6 +23,7 @@ dgit (2.12~) unstable; urgency=medium on a patch during .dsc import. Apropos of #848391. * Do not fail to import a .dsc containing patches which patch files multiple times, due to #848611. Closes:#848391. + * Do not fail to import a .dsc containing patches to .git/ (!) Test suite: * Provide and use stunt lintian and debuild, to avoid lintian -- 2.30.2