feat(bin): starship script to list remote icon
This commit is contained in:
parent
aac556d735
commit
d932529e8c
1 changed files with 13 additions and 0 deletions
13
.local/bin/check-git-remote
Executable file
13
.local/bin/check-git-remote
Executable file
|
@ -0,0 +1,13 @@
|
|||
#!/usr/bin/env bash
|
||||
|
||||
GIT_REMOTE=$(command git ls-remote --get-url 2>/dev/null)
|
||||
if [[ "$GIT_REMOTE" =~ "github" ]]; then
|
||||
GIT_REMOTE_SYMBOL=" "
|
||||
elif [[ "$GIT_REMOTE" =~ "gitlab" ]]; then
|
||||
GIT_REMOTE_SYMBOL=" "
|
||||
elif [[ "$GIT_REMOTE" =~ "bitbucket" ]]; then
|
||||
GIT_REMOTE_SYMBOL=" "
|
||||
else
|
||||
GIT_REMOTE_SYMBOL=" "
|
||||
fi
|
||||
echo "$GIT_REMOTE_SYMBOL "
|
Loading…
Add table
Reference in a new issue