Skip to content

Commit

Permalink
rebase: use git rev-parse -q
Browse files Browse the repository at this point in the history
Signed-off-by: Miklos Vajna <vmiklos@frugalware.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
  • Loading branch information
Miklos Vajna authored and Junio C Hamano committed Dec 3, 2008
1 parent 2d17985 commit 5a92d19
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions git-rebase.sh
Original file line number Diff line number Diff line change
Expand Up @@ -365,10 +365,10 @@ case "$#" in
switch_to="$2"

if git show-ref --verify --quiet -- "refs/heads/$2" &&
branch=$(git rev-parse --verify "refs/heads/$2" 2>/dev/null)
branch=$(git rev-parse -q --verify "refs/heads/$2")
then
head_name="refs/heads/$2"
elif branch=$(git rev-parse --verify "$2" 2>/dev/null)
elif branch=$(git rev-parse -q --verify "$2")
then
head_name="detached HEAD"
else
Expand Down

0 comments on commit 5a92d19

Please sign in to comment.