contrib/makerepo: check that reapplying patch succeeded in makerepo.sh

Signed-off-by: Thomas Haller <thaller@redhat.com>
This commit is contained in:
Thomas Haller 2014-04-11 16:06:11 +02:00
parent 0cadf0ad44
commit cae868f689

View file

@ -136,6 +136,7 @@ pushd "$DIRNAME"
git commit --allow-empty -m '*** empty initial commit' # useful, to rebase the following commit
git add -f -A .
git commit -m '*** add all'
ORIG_HEAD="`git rev-parse HEAD`"
cat ../makerepo.gitignore > .gitignore
git rm --cached -r .
git add --all .
@ -206,8 +207,13 @@ pushd "$DIRNAME"
git commit --allow-empty -m "$COMMIT_MSG"
fi
git reset --hard HEAD
git clean -fdx
[[ x = "x$(git diff "${BASECOMMIT[$((i+1))]}" HEAD)" ]] || die "error reverting patch"
done
fi
git checkout "$ORIG_HEAD" -- .
git checkout HEAD~ -- .gitignore
git reset
popd
if [[ $LOCAL != 0 ]]; then
@ -220,3 +226,4 @@ if [[ $LOCAL != 0 ]]; then
popd
fi
echo SUCCESS;