aboutsummaryrefslogtreecommitdiff
path: root/git-revert.sh
diff options
context:
space:
mode:
Diffstat (limited to 'git-revert.sh')
-rwxr-xr-xgit-revert.sh6
1 files changed, 6 insertions, 0 deletions
diff --git a/git-revert.sh b/git-revert.sh
index c74af99a5..bb8f1ca24 100755
--- a/git-revert.sh
+++ b/git-revert.sh
@@ -146,6 +146,12 @@ cherry-pick)
esac >.msg
+eval GITHEAD_$head=HEAD
+eval GITHEAD_$next='`git show -s \
+ --pretty=oneline --encoding="$encoding" "$commit" |
+ sed -e "s/^[^ ]* //"`'
+export GITHEAD_$head GITHEAD_$next
+
# This three way merge is an interesting one. We are at
# $head, and would want to apply the change between $commit
# and $prev on top of us (when reverting), or the change between