shgit: quote glob characters
This commit is contained in:
parent
febb52129e
commit
d5e94cd65e
@ -1,5 +1,5 @@
|
||||
# shgit
|
||||
# Written in 2019 by Lucas
|
||||
# Written in 2019,2021 by Lucas
|
||||
# CC0 1.0 Universal/Public domain - No rights reserved
|
||||
#
|
||||
# To the extent possible under law, the author(s) have dedicated all
|
||||
@ -21,7 +21,7 @@ shgit()
|
||||
|
||||
if ! name=$(git symbolic-ref -q --short HEAD); then
|
||||
name=$(git rev-parse --short HEAD 2>/dev/null)
|
||||
name=${name:-?}
|
||||
name=${name:-"?"}
|
||||
fi
|
||||
|
||||
rb=
|
||||
@ -39,10 +39,10 @@ shgit()
|
||||
status=
|
||||
if [ "$worktree" = "true" ]; then
|
||||
if [ -n "$(git status --porcelain)" ]; then
|
||||
status=${SHGIT_SEP}*
|
||||
status=$SHGIT_SEP"*"
|
||||
fi
|
||||
else
|
||||
status=${SHGIT_SEP}?
|
||||
status=$SHGIT_SEP"?"
|
||||
fi
|
||||
|
||||
oldIFS=$IFS
|
||||
|
Loading…
Reference in New Issue
Block a user