summaryrefslogtreecommitdiff
path: root/t/t3501-revert-cherry-pick.sh
diff options
context:
space:
mode:
authorChristian Couder <chriscool@tuxfamily.org>2010-06-12 18:05:12 +0200
committerJunio C Hamano <gitster@pobox.com>2010-06-13 09:42:38 -0700
commit643cb5f7c99e77a4a3e97213dd226a7dc2650c02 (patch)
tree9eaf300ca31ad8b4a382e8990843c68bbf144b1f /t/t3501-revert-cherry-pick.sh
parent0d4dbcd35e89a549055e34daf410e4579571b984 (diff)
downloadgit-643cb5f7c99e77a4a3e97213dd226a7dc2650c02.tar.gz
commit: use value of GIT_REFLOG_ACTION env variable as reflog message
The environment variable GIT_REFLOG_ACTION was used by git-commit.sh, but when it was converted to a builtin (f5bbc3225c4b073a7ff3218164a0c820299bc9c6, Port git commit to C, Nov 8 2007) this was lost. Let's use it again as it is more user friendly when reverting or cherry-picking to see "revert" or "cherry-pick" in the reflog rather than to just see "commit". Signed-off-by: Christian Couder <chriscool@tuxfamily.org> Acked-by: Jonathan Nieder <jrnieder@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 't/t3501-revert-cherry-pick.sh')
-rwxr-xr-xt/t3501-revert-cherry-pick.sh6
1 files changed, 4 insertions, 2 deletions
diff --git a/t/t3501-revert-cherry-pick.sh b/t/t3501-revert-cherry-pick.sh
index 7f858151d4..e4fbf7a210 100755
--- a/t/t3501-revert-cherry-pick.sh
+++ b/t/t3501-revert-cherry-pick.sh
@@ -47,7 +47,8 @@ test_expect_success 'cherry-pick after renaming branch' '
git cherry-pick added &&
test $(git rev-parse HEAD^) = $(git rev-parse rename2) &&
test -f opos &&
- grep "Add extra line at the end" opos
+ grep "Add extra line at the end" opos &&
+ git reflog -1 | grep cherry-pick
'
@@ -57,7 +58,8 @@ test_expect_success 'revert after renaming branch' '
git revert added &&
test $(git rev-parse HEAD^) = $(git rev-parse rename1) &&
test -f spoo &&
- ! grep "Add extra line at the end" spoo
+ ! grep "Add extra line at the end" spoo &&
+ git reflog -1 | grep revert
'