pull: use git rev-parse -q
Signed-off-by: Miklos Vajna <vmiklos@frugalware.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:
parent
a86e8c1cfc
commit
2d17985782
@ -121,13 +121,13 @@ test true = "$rebase" && {
|
|||||||
test -z "$origin" && origin=$(get_default_remote)
|
test -z "$origin" && origin=$(get_default_remote)
|
||||||
reflist="$(get_remote_refs_for_fetch "$@" 2>/dev/null |
|
reflist="$(get_remote_refs_for_fetch "$@" 2>/dev/null |
|
||||||
sed "s|refs/heads/\(.*\):|\1|")" &&
|
sed "s|refs/heads/\(.*\):|\1|")" &&
|
||||||
oldremoteref="$(git rev-parse --verify \
|
oldremoteref="$(git rev-parse -q --verify \
|
||||||
"refs/remotes/$origin/$reflist" 2>/dev/null)"
|
"refs/remotes/$origin/$reflist")"
|
||||||
}
|
}
|
||||||
orig_head=$(git rev-parse --verify HEAD 2>/dev/null)
|
orig_head=$(git rev-parse -q --verify HEAD)
|
||||||
git fetch $verbosity --update-head-ok "$@" || exit 1
|
git fetch $verbosity --update-head-ok "$@" || exit 1
|
||||||
|
|
||||||
curr_head=$(git rev-parse --verify HEAD 2>/dev/null)
|
curr_head=$(git rev-parse -q --verify HEAD)
|
||||||
if test -n "$orig_head" && test "$curr_head" != "$orig_head"
|
if test -n "$orig_head" && test "$curr_head" != "$orig_head"
|
||||||
then
|
then
|
||||||
# The fetch involved updating the current branch.
|
# The fetch involved updating the current branch.
|
||||||
|
Loading…
Reference in New Issue
Block a user