File tree Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -420,7 +420,7 @@ if [ "$ZSH_VERSION" ] && [ "$0" != 'ksh' ] \
420
420
421
421
# Only display the $HOSTNAME for an ssh connection, except for a superuser
422
422
if _polyglot_is_ssh || _polyglot_is_superuser; then
423
- psvar[1]=${HOST%% .* }
423
+ psvar[1]=${HOST%% \ .* }
424
424
else
425
425
psvar[1]=' '
426
426
fi
@@ -536,7 +536,7 @@ elif [ "$KSH_VERSION" ] || _polyglot_is_dtksh || [ "$ZSH_VERSION" ] \
536
536
# Only display the $HOSTNAME for an ssh connection
537
537
if _polyglot_is_ssh || _polyglot_is_superuser; then
538
538
POLYGLOT_HOSTNAME_STRING=$( hostname)
539
- POLYGLOT_HOSTNAME_STRING=" @${POLYGLOT_HOSTNAME_STRING%% .* } "
539
+ POLYGLOT_HOSTNAME_STRING=" @${POLYGLOT_HOSTNAME_STRING%% \ .* } "
540
540
else
541
541
POLYGLOT_HOSTNAME_STRING=' '
542
542
fi
@@ -632,7 +632,7 @@ elif _polyglot_is_pdksh || [ "$0" = 'dash' ] || _polyglot_is_busybox \
632
632
# Only display the $HOSTNAME for an ssh connection
633
633
if _polyglot_is_ssh || _polyglot_is_superuser; then
634
634
POLYGLOT_HOSTNAME_STRING=$( hostname)
635
- POLYGLOT_HOSTNAME_STRING=" @${POLYGLOT_HOSTNAME_STRING% ? ${POLYGLOT_HOSTNAME_STRING #* .} } "
635
+ POLYGLOT_HOSTNAME_STRING=" @${POLYGLOT_HOSTNAME_STRING%% \. * } "
636
636
else
637
637
POLYGLOT_HOSTNAME_STRING=' '
638
638
fi
You can’t perform that action at this time.
0 commit comments