diff options
-rwxr-xr-x | git-base.sh | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/git-base.sh b/git-base.sh index a110056..d6401e5 100755 --- a/git-base.sh +++ b/git-base.sh @@ -125,7 +125,7 @@ readable_branch_name() { remote_branch_name() { if is_repo; then - local remoteBranch="$(git for-each-ref --format='%(upstream:short)' refs/heads | grep "$(branch_name)")" + local remoteBranch="$(git for-each-ref --format='%(upstream:short)' refs/heads "$(git symbolic-ref -q HEAD)" )" if [[ -n $remoteBranch ]]; then echo $remoteBranch return 0 |