cabal unpack --pristine

Without --pristine, cabal will update the package's cabal file if a newer
one is available in hackage. But that can break applying patches.
Especially since the new version from hackage can apparently have dos line
endings, while the version from the tarball doesn't.
This commit is contained in:
Joey Hess 2014-12-04 01:02:36 -04:00
parent 9dbd2ff6c2
commit 33d6057ca3
2 changed files with 4 additions and 4 deletions

View file

@ -32,9 +32,9 @@ patched () {
ver="$(grep " $pkg " ../cabal.config | cut -d= -f 3 | sed 's/,$//')"
fi
if [ -z "$ver" ]; then
cabal unpack $pkg
cabal unpack --pristine $pkg
else
cabal unpack $pkg-$ver
cabal unpack --pristine $pkg-$ver
fi
cd $pkg*
git init

View file

@ -28,9 +28,9 @@ patched () {
ver="$(grep " $pkg " ../cabal.config | cut -d= -f 3 | sed 's/,$//')"
fi
if [ -z "$ver" ]; then
cabal unpack $pkg
cabal unpack --pristine $pkg
else
cabal unpack $pkg-$ver
cabal unpack --pristine $pkg-$ver
fi
cd $pkg*
git init