Skip to content

Commit 12b99c1

Browse files
committed
Code cleanup
1 parent 851ad97 commit 12b99c1

File tree

1 file changed

+12
-12
lines changed

1 file changed

+12
-12
lines changed

agkozak-zsh-prompt.plugin.zsh

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -61,17 +61,6 @@ if (( AGKOZAK_PROMPT_DEBUG )); then
6161
fi
6262
fi
6363

64-
###########################################################
65-
# Are colors available?
66-
#
67-
# Globals:
68-
# AGKOZAK_HAS_COLORS
69-
###########################################################
70-
_agkozak_has_colors() {
71-
typeset -g AGKOZAK_HAS_COLORS=${AGKOZAK_HAS_COLORS:-$(( $(tput colors) >= 8 ? 1 : 0 ))}
72-
(( AGKOZAK_HAS_COLORS ))
73-
}
74-
7564
# Set AGKOZAK_MULTILINE to 0 to enable the legacy, single-line prompt
7665
typeset -g AGKOZAK_MULTILINE=${AGKOZAK_MULTILINE:-1}
7766

@@ -91,6 +80,17 @@ setopt PROMPT_SUBST NO_PROMPT_BANG
9180
# BASIC FUNCTIONS
9281
############################################################
9382

83+
###########################################################
84+
# Are colors available?
85+
#
86+
# Globals:
87+
# AGKOZAK_HAS_COLORS
88+
###########################################################
89+
_agkozak_has_colors() {
90+
typeset -g AGKOZAK_HAS_COLORS=${AGKOZAK_HAS_COLORS:-$(( $(tput colors) >= 8 ? 1 : 0 ))}
91+
(( AGKOZAK_HAS_COLORS ))
92+
}
93+
9494
############################################################
9595
# Is the user connected via SSH?
9696
#
@@ -176,7 +176,7 @@ _agkozak_branch_changes() {
176176
esac
177177
done
178178

179-
[[ -n $symbols ]] && printf ' %s' "${symbols//asterisk/*}"
179+
[[ -n $symbols ]] && printf ' %s' "${symbols}"
180180
}
181181

182182
############################################################

0 commit comments

Comments
 (0)