diff options
Diffstat (limited to 'git-prompt.sh')
-rwxr-xr-x | git-prompt.sh | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/git-prompt.sh b/git-prompt.sh index 3025f95..28e2de6 100755 --- a/git-prompt.sh +++ b/git-prompt.sh @@ -62,6 +62,7 @@ max_file_list_length=${max_file_list_length:-100} + short_hostname=${short_hostname:-off} upcase_hostname=${upcase_hostname:-on} count_only=${count_only:-off} rawhex_len=${rawhex_len:-5} @@ -297,7 +298,9 @@ set_shell_label() { #then host=${HOSTNAME} - #host=`hostname -s` + if [[ $short_hostname = "on" ]]; then + host=`hostname -s` + fi host=${host#$default_host} uphost=`echo ${host} | tr a-z A-Z` if [[ $upcase_hostname = "on" ]]; then |