Shorten long branch names

This commit is contained in:
Abhishek Keshri 2022-12-01 18:07:19 +05:30
parent deba37eed1
commit 5583124d0b
No known key found for this signature in database
GPG key ID: 62BD6AA2E913B3D3

View file

@ -102,7 +102,7 @@ checkForGitDir()
getBranch() getBranch()
{ {
if [ $(checkForGitDir) == "true" ]; then if [ $(checkForGitDir) == "true" ]; then
echo $(git -C $path rev-parse --abbrev-ref HEAD) printf "%.20s " $(git -C $path rev-parse --abbrev-ref HEAD)
else else
echo $no_repo_message echo $no_repo_message
fi fi