Compare commits
2 commits
5ddb3218cb
...
2f2af2e0c0
| Author | SHA1 | Date | |
|---|---|---|---|
| 2f2af2e0c0 | |||
| 791c1d9e0b |
1 changed files with 2 additions and 2 deletions
4
gis
4
gis
|
|
@ -183,7 +183,7 @@ for dir in "${git_dirs[@]}"; do
|
|||
|
||||
# Get origin head
|
||||
if git symbolic-ref refs/remotes/origin/HEAD > /dev/null 2>&1; then
|
||||
[[ $(git symbolic-ref refs/remotes/origin/HEAD) =~ \/([^\/]*)$ ]] &>/dev/null && origin_head="${BASH_REMATCH[1]}"
|
||||
[[ $(git symbolic-ref refs/remotes/origin/HEAD) =~ refs/remotes/origin/(.*)$ ]] &>/dev/null && origin_head="${BASH_REMATCH[1]}"
|
||||
else
|
||||
origin_head="$current_branch"
|
||||
fi
|
||||
|
|
@ -248,7 +248,7 @@ for dir in "${git_dirs[@]}"; do
|
|||
fi
|
||||
if [ "$current_branch" != "$origin_head" ]; then
|
||||
num_additional_branches=$(( num_additional_branches - 1 ))
|
||||
output="${output} (${origin_head}${text_reset})"
|
||||
output="${output} (${origin_head})"
|
||||
fi
|
||||
if [[ $num_additional_branches -gt 0 ]]; then
|
||||
output="${output} (+${num_additional_branches})"
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue