Honor GIT_REFLOG_ACTION in git-rebase.
To help correctly log actions caused by porcelain which invoke git-reset directly we should honor the setting of GIT_REFLOG_ACTION which we inherited from our caller. Signed-off-by: Shawn O. Pearce <spearce@spearce.org> Signed-off-by: Junio C Hamano <junkio@cox.net>
This commit is contained in:
parent
f94741324e
commit
42ea5a5784
@ -5,6 +5,7 @@
|
|||||||
USAGE='[--mixed | --soft | --hard] [<commit-ish>] [ [--] <paths>...]'
|
USAGE='[--mixed | --soft | --hard] [<commit-ish>] [ [--] <paths>...]'
|
||||||
SUBDIRECTORY_OK=Yes
|
SUBDIRECTORY_OK=Yes
|
||||||
. git-sh-setup
|
. git-sh-setup
|
||||||
|
set_reflog_action "reset $*"
|
||||||
|
|
||||||
update= reset_type=--mixed
|
update= reset_type=--mixed
|
||||||
unset rev
|
unset rev
|
||||||
@ -81,7 +82,7 @@ then
|
|||||||
else
|
else
|
||||||
rm -f "$GIT_DIR/ORIG_HEAD"
|
rm -f "$GIT_DIR/ORIG_HEAD"
|
||||||
fi
|
fi
|
||||||
git-update-ref -m "reset $reset_type $*" HEAD "$rev"
|
git-update-ref -m "$GIT_REFLOG_ACTION" HEAD "$rev"
|
||||||
update_ref_status=$?
|
update_ref_status=$?
|
||||||
|
|
||||||
case "$reset_type" in
|
case "$reset_type" in
|
||||||
|
Loading…
Reference in New Issue
Block a user