echo "Error $1 occurred"
if [ x"${orig_branch}" != x"" ]; then
+ if git status | grep -q "currently cherry-picking commit"; then
+ git cherry-pick --abort
+ fi
+
+ if git status | grep -q "currently editing a commit while rebasing branch"; then
+ git rebase --abort
+ fi
+
git checkout ${orig_branch}
- git rebase --abort
fi
fi