1# Generated by Powerlevel10k configuration wizard on 2021-11-28 at 19:21 EST.
2# Based on romkatv/powerlevel10k/config/p10k-lean.zsh, checksum 54401.
3# Wizard options: nerdfont-complete + powerline, small icons, unicode, lean, 24h time,
4# 2 lines, dotted, full frame, light-ornaments, sparse, few icons, concise,
5# transient_prompt, instant_prompt=verbose.
6# Type `p10k configure` to generate another config.
7#
8# Config for Powerlevel10k with lean prompt style. Type `p10k configure` to generate
9# your own config based on it.
10#
11# Tip: Looking for a nice color? Here's a one-liner to print colormap.
12#
13# for i in {0..255}; do print -Pn "%K{$i} %k%F{$i}${(l:3::0:)i}%f " ${${(M)$((i%6)):#3}:+$'\n'}; done
14
15# Temporarily change options.
16'builtin' 'local' '-a' 'p10k_config_opts'
17[[ ! -o 'aliases' ]] || p10k_config_opts+=('aliases')
18[[ ! -o 'sh_glob' ]] || p10k_config_opts+=('sh_glob')
19[[ ! -o 'no_brace_expand' ]] || p10k_config_opts+=('no_brace_expand')
20'builtin' 'setopt' 'no_aliases' 'no_sh_glob' 'brace_expand'
21
22() {
23 emulate -L zsh -o extended_glob
24
25 # Unset all configuration options. This allows you to apply configuration changes without
26 # restarting zsh. Edit ~/.p10k.zsh and type `source ~/.p10k.zsh`.
27 unset -m '(POWERLEVEL9K_*|DEFAULT_USER)~POWERLEVEL9K_GITSTATUS_DIR'
28
29 # Zsh >= 5.1 is required.
30 autoload -Uz is-at-least && is-at-least 5.1 || return
31
32 # The list of segments shown on the left. Fill it with the most important segments.
33 typeset -g POWERLEVEL9K_LEFT_PROMPT_ELEMENTS=(
34 # =========================[ Line #1 ]=========================
35 # os_icon # os identifier
36 dir # current directory
37 vcs # git status
38 # =========================[ Line #2 ]=========================
39 newline # \n
40 prompt_char # prompt symbol
41 )
42
43 # The list of segments shown on the right. Fill it with less important segments.
44 # Right prompt on the last prompt line (where you are typing your commands) gets
45 # automatically hidden when the input line reaches it. Right prompt above the
46 # last prompt line gets hidden if it would overlap with left prompt.
47 typeset -g POWERLEVEL9K_RIGHT_PROMPT_ELEMENTS=(
48 # =========================[ Line #1 ]=========================
49 status # exit code of the last command
50 command_execution_time # duration of the last command
51 background_jobs # presence of background jobs
52 direnv # direnv status (https://direnv.net/)
53 asdf # asdf version manager (https://github.com/asdf-vm/asdf)
54 virtualenv # python virtual environment (https://docs.python.org/3/library/venv.html)
55 anaconda # conda environment (https://conda.io/)
56 pyenv # python environment (https://github.com/pyenv/pyenv)
57 goenv # go environment (https://github.com/syndbg/goenv)
58 nodenv # node.js version from nodenv (https://github.com/nodenv/nodenv)
59 nvm # node.js version from nvm (https://github.com/nvm-sh/nvm)
60 nodeenv # node.js environment (https://github.com/ekalinin/nodeenv)
61 # node_version # node.js version
62 # go_version # go version (https://golang.org)
63 # rust_version # rustc version (https://www.rust-lang.org)
64 # dotnet_version # .NET version (https://dotnet.microsoft.com)
65 # php_version # php version (https://www.php.net/)
66 # laravel_version # laravel php framework version (https://laravel.com/)
67 # java_version # java version (https://www.java.com/)
68 # package # name@version from package.json (https://docs.npmjs.com/files/package.json)
69 rbenv # ruby version from rbenv (https://github.com/rbenv/rbenv)
70 rvm # ruby version from rvm (https://rvm.io)
71 fvm # flutter version management (https://github.com/leoafarias/fvm)
72 luaenv # lua version from luaenv (https://github.com/cehoffman/luaenv)
73 jenv # java version from jenv (https://github.com/jenv/jenv)
74 plenv # perl version from plenv (https://github.com/tokuhirom/plenv)
75 phpenv # php version from phpenv (https://github.com/phpenv/phpenv)
76 scalaenv # scala version from scalaenv (https://github.com/scalaenv/scalaenv)
77 haskell_stack # haskell version from stack (https://haskellstack.org/)
78 kubecontext # current kubernetes context (https://kubernetes.io/)
79 terraform # terraform workspace (https://www.terraform.io)
80 # terraform_version # terraform version (https://www.terraform.io)
81 aws # aws profile (https://docs.aws.amazon.com/cli/latest/userguide/cli-configure-profiles.html)
82 aws_eb_env # aws elastic beanstalk environment (https://aws.amazon.com/elasticbeanstalk/)
83 azure # azure account name (https://docs.microsoft.com/en-us/cli/azure)
84 gcloud # google cloud cli account and project (https://cloud.google.com/)
85 google_app_cred # google application credentials (https://cloud.google.com/docs/authentication/production)
86 toolbox # toolbox name (https://github.com/containers/toolbox)
87 context # user@hostname
88 nordvpn # nordvpn connection status, linux only (https://nordvpn.com/)
89 ranger # ranger shell (https://github.com/ranger/ranger)
90 nnn # nnn shell (https://github.com/jarun/nnn)
91 xplr # xplr shell (https://github.com/sayanarijit/xplr)
92 vim_shell # vim shell indicator (:sh)
93 midnight_commander # midnight commander shell (https://midnight-commander.org/)
94 nix_shell # nix shell (https://nixos.org/nixos/nix-pills/developing-with-nix-shell.html)
95 # vpn_ip # virtual private network indicator
96 # load # CPU load
97 # disk_usage # disk usage
98 # ram # free RAM
99 # swap # used swap
100 todo # todo items (https://github.com/todotxt/todo.txt-cli)
101 timewarrior # timewarrior tracking status (https://timewarrior.net/)
102 taskwarrior # taskwarrior task count (https://taskwarrior.org/)
103 time # current time
104 # =========================[ Line #2 ]=========================
105 newline
106 ip # ip address and bandwidth usage for a specified network interface
107 public_ip # public IP address
108 # proxy # system-wide http/https/ftp proxy
109 # battery # internal battery
110 # wifi # wifi speed
111 # example # example user-defined segment (see prompt_example function below)
112 )
113
114 # Defines character set used by powerlevel10k. It's best to let `p10k configure` set it for you.
115 typeset -g POWERLEVEL9K_MODE=nerdfont-complete
116 # When set to `moderate`, some icons will have an extra space after them. This is meant to avoid
117 # icon overlap when using non-monospace fonts. When set to `none`, spaces are not added.
118 typeset -g POWERLEVEL9K_ICON_PADDING=none
119
120 # Basic style options that define the overall look of your prompt. You probably don't want to
121 # change them.
122 typeset -g POWERLEVEL9K_BACKGROUND= # transparent background
123 typeset -g POWERLEVEL9K_{LEFT,RIGHT}_{LEFT,RIGHT}_WHITESPACE= # no surrounding whitespace
124 typeset -g POWERLEVEL9K_{LEFT,RIGHT}_SUBSEGMENT_SEPARATOR=' ' # separate segments with a space
125 typeset -g POWERLEVEL9K_{LEFT,RIGHT}_SEGMENT_SEPARATOR= # no end-of-line symbol
126
127 # When set to true, icons appear before content on both sides of the prompt. When set
128 # to false, icons go after content. If empty or not set, icons go before content in the left
129 # prompt and after content in the right prompt.
130 #
131 # You can also override it for a specific segment:
132 #
133 # POWERLEVEL9K_STATUS_ICON_BEFORE_CONTENT=false
134 #
135 # Or for a specific segment in specific state:
136 #
137 # POWERLEVEL9K_DIR_NOT_WRITABLE_ICON_BEFORE_CONTENT=false
138 typeset -g POWERLEVEL9K_ICON_BEFORE_CONTENT=true
139
140 # Add an empty line before each prompt.
141 typeset -g POWERLEVEL9K_PROMPT_ADD_NEWLINE=true
142
143 # Connect left prompt lines with these symbols.
144 typeset -g POWERLEVEL9K_MULTILINE_FIRST_PROMPT_PREFIX='%242F╭─'
145 typeset -g POWERLEVEL9K_MULTILINE_NEWLINE_PROMPT_PREFIX='%242F├─'
146 typeset -g POWERLEVEL9K_MULTILINE_LAST_PROMPT_PREFIX='%242F╰─'
147 # Connect right prompt lines with these symbols.
148 typeset -g POWERLEVEL9K_MULTILINE_FIRST_PROMPT_SUFFIX='%242F─╮'
149 typeset -g POWERLEVEL9K_MULTILINE_NEWLINE_PROMPT_SUFFIX='%242F─┤'
150 typeset -g POWERLEVEL9K_MULTILINE_LAST_PROMPT_SUFFIX='%242F─╯'
151
152 # The left end of left prompt.
153 typeset -g POWERLEVEL9K_LEFT_PROMPT_FIRST_SEGMENT_START_SYMBOL=' '
154 # The right end of right prompt.
155 typeset -g POWERLEVEL9K_RIGHT_PROMPT_LAST_SEGMENT_END_SYMBOL=' '
156
157 # Ruler, a.k.a. the horizontal line before each prompt. If you set it to true, you'll
158 # probably want to set POWERLEVEL9K_PROMPT_ADD_NEWLINE=false above and
159 # POWERLEVEL9K_MULTILINE_FIRST_PROMPT_GAP_CHAR=' ' below.
160 typeset -g POWERLEVEL9K_SHOW_RULER=false
161 typeset -g POWERLEVEL9K_RULER_CHAR='─' # reasonable alternative: '·'
162 typeset -g POWERLEVEL9K_RULER_FOREGROUND=242
163
164 # Filler between left and right prompt on the first prompt line. You can set it to '·' or '─'
165 # to make it easier to see the alignment between left and right prompt and to separate prompt
166 # from command output. It serves the same purpose as ruler (see above) without increasing
167 # the number of prompt lines. You'll probably want to set POWERLEVEL9K_SHOW_RULER=false
168 # if using this. You might also like POWERLEVEL9K_PROMPT_ADD_NEWLINE=false for more compact
169 # prompt.
170 typeset -g POWERLEVEL9K_MULTILINE_FIRST_PROMPT_GAP_CHAR='·'
171 if [[ $POWERLEVEL9K_MULTILINE_FIRST_PROMPT_GAP_CHAR != ' ' ]]; then
172 # The color of the filler.
173 typeset -g POWERLEVEL9K_MULTILINE_FIRST_PROMPT_GAP_FOREGROUND=242
174 # Add a space between the end of left prompt and the filler.
175 typeset -g POWERLEVEL9K_LEFT_PROMPT_LAST_SEGMENT_END_SYMBOL=' '
176 # Add a space between the filler and the start of right prompt.
177 typeset -g POWERLEVEL9K_RIGHT_PROMPT_FIRST_SEGMENT_START_SYMBOL=' '
178 # Start filler from the edge of the screen if there are no left segments on the first line.
179 typeset -g POWERLEVEL9K_EMPTY_LINE_LEFT_PROMPT_FIRST_SEGMENT_END_SYMBOL='%{%}'
180 # End filler on the edge of the screen if there are no right segments on the first line.
181 typeset -g POWERLEVEL9K_EMPTY_LINE_RIGHT_PROMPT_FIRST_SEGMENT_START_SYMBOL='%{%}'
182 fi
183
184 #################################[ os_icon: os identifier ]##################################
185 # OS identifier color.
186 typeset -g POWERLEVEL9K_OS_ICON_FOREGROUND=
187 # Custom icon.
188 # typeset -g POWERLEVEL9K_OS_ICON_CONTENT_EXPANSION='⭐'
189
190 ################################[ prompt_char: prompt symbol ]################################
191 # Green prompt symbol if the last command succeeded.
192 typeset -g POWERLEVEL9K_PROMPT_CHAR_OK_{VIINS,VICMD,VIVIS,VIOWR}_FOREGROUND=76
193 # Red prompt symbol if the last command failed.
194 typeset -g POWERLEVEL9K_PROMPT_CHAR_ERROR_{VIINS,VICMD,VIVIS,VIOWR}_FOREGROUND=196
195 # Default prompt symbol.
196 typeset -g POWERLEVEL9K_PROMPT_CHAR_{OK,ERROR}_VIINS_CONTENT_EXPANSION='❯'
197 # Prompt symbol in command vi mode.
198 typeset -g POWERLEVEL9K_PROMPT_CHAR_{OK,ERROR}_VICMD_CONTENT_EXPANSION='❮'
199 # Prompt symbol in visual vi mode.
200 typeset -g POWERLEVEL9K_PROMPT_CHAR_{OK,ERROR}_VIVIS_CONTENT_EXPANSION='V'
201 # Prompt symbol in overwrite vi mode.
202 typeset -g POWERLEVEL9K_PROMPT_CHAR_{OK,ERROR}_VIOWR_CONTENT_EXPANSION='▶'
203 typeset -g POWERLEVEL9K_PROMPT_CHAR_OVERWRITE_STATE=true
204 # No line terminator if prompt_char is the last segment.
205 typeset -g POWERLEVEL9K_PROMPT_CHAR_LEFT_PROMPT_LAST_SEGMENT_END_SYMBOL=''
206 # No line introducer if prompt_char is the first segment.
207 typeset -g POWERLEVEL9K_PROMPT_CHAR_LEFT_PROMPT_FIRST_SEGMENT_START_SYMBOL=
208
209 ##################################[ dir: current directory ]##################################
210 # Default current directory color.
211 typeset -g POWERLEVEL9K_DIR_FOREGROUND=31
212 # If directory is too long, shorten some of its segments to the shortest possible unique
213 # prefix. The shortened directory can be tab-completed to the original.
214 typeset -g POWERLEVEL9K_SHORTEN_STRATEGY=truncate_to_unique
215 # Replace removed segment suffixes with this symbol.
216 typeset -g POWERLEVEL9K_SHORTEN_DELIMITER=
217 # Color of the shortened directory segments.
218 typeset -g POWERLEVEL9K_DIR_SHORTENED_FOREGROUND=103
219 # Color of the anchor directory segments. Anchor segments are never shortened. The first
220 # segment is always an anchor.
221 typeset -g POWERLEVEL9K_DIR_ANCHOR_FOREGROUND=39
222 # Display anchor directory segments in bold.
223 typeset -g POWERLEVEL9K_DIR_ANCHOR_BOLD=true
224 # Don't shorten directories that contain any of these files. They are anchors.
225 local anchor_files=(
226 .bzr
227 .citc
228 .git
229 .hg
230 .node-version
231 .python-version
232 .go-version
233 .ruby-version
234 .lua-version
235 .java-version
236 .perl-version
237 .php-version
238 .tool-version
239 .shorten_folder_marker
240 .svn
241 .terraform
242 CVS
243 Cargo.toml
244 composer.json
245 go.mod
246 package.json
247 stack.yaml
248 )
249 typeset -g POWERLEVEL9K_SHORTEN_FOLDER_MARKER="(${(j:|:)anchor_files})"
250 # If set to "first" ("last"), remove everything before the first (last) subdirectory that contains
251 # files matching $POWERLEVEL9K_SHORTEN_FOLDER_MARKER. For example, when the current directory is
252 # /foo/bar/git_repo/nested_git_repo/baz, prompt will display git_repo/nested_git_repo/baz (first)
253 # or nested_git_repo/baz (last). This assumes that git_repo and nested_git_repo contain markers
254 # and other directories don't.
255 #
256 # Optionally, "first" and "last" can be followed by ":<offset>" where <offset> is an integer.
257 # This moves the truncation point to the right (positive offset) or to the left (negative offset)
258 # relative to the marker. Plain "first" and "last" are equivalent to "first:0" and "last:0"
259 # respectively.
260 typeset -g POWERLEVEL9K_DIR_TRUNCATE_BEFORE_MARKER=false
261 # Don't shorten this many last directory segments. They are anchors.
262 typeset -g POWERLEVEL9K_SHORTEN_DIR_LENGTH=1
263 # Shorten directory if it's longer than this even if there is space for it. The value can
264 # be either absolute (e.g., '80') or a percentage of terminal width (e.g, '50%'). If empty,
265 # directory will be shortened only when prompt doesn't fit or when other parameters demand it
266 # (see POWERLEVEL9K_DIR_MIN_COMMAND_COLUMNS and POWERLEVEL9K_DIR_MIN_COMMAND_COLUMNS_PCT below).
267 # If set to `0`, directory will always be shortened to its minimum length.
268 typeset -g POWERLEVEL9K_DIR_MAX_LENGTH=80
269 # When `dir` segment is on the last prompt line, try to shorten it enough to leave at least this
270 # many columns for typing commands.
271 typeset -g POWERLEVEL9K_DIR_MIN_COMMAND_COLUMNS=40
272 # When `dir` segment is on the last prompt line, try to shorten it enough to leave at least
273 # COLUMNS * POWERLEVEL9K_DIR_MIN_COMMAND_COLUMNS_PCT * 0.01 columns for typing commands.
274 typeset -g POWERLEVEL9K_DIR_MIN_COMMAND_COLUMNS_PCT=50
275 # If set to true, embed a hyperlink into the directory. Useful for quickly
276 # opening a directory in the file manager simply by clicking the link.
277 # Can also be handy when the directory is shortened, as it allows you to see
278 # the full directory that was used in previous commands.
279 typeset -g POWERLEVEL9K_DIR_HYPERLINK=false
280
281 # Enable special styling for non-writable and non-existent directories. See POWERLEVEL9K_LOCK_ICON
282 # and POWERLEVEL9K_DIR_CLASSES below.
283 typeset -g POWERLEVEL9K_DIR_SHOW_WRITABLE=v3
284
285 # The default icon shown next to non-writable and non-existent directories when
286 # POWERLEVEL9K_DIR_SHOW_WRITABLE is set to v3.
287 # typeset -g POWERLEVEL9K_LOCK_ICON='⭐'
288
289 # POWERLEVEL9K_DIR_CLASSES allows you to specify custom icons and colors for different
290 # directories. It must be an array with 3 * N elements. Each triplet consists of:
291 #
292 # 1. A pattern against which the current directory ($PWD) is matched. Matching is done with
293 # extended_glob option enabled.
294 # 2. Directory class for the purpose of styling.
295 # 3. An empty string.
296 #
297 # Triplets are tried in order. The first triplet whose pattern matches $PWD wins.
298 #
299 # If POWERLEVEL9K_DIR_SHOW_WRITABLE is set to v3, non-writable and non-existent directories
300 # acquire class suffix _NOT_WRITABLE and NON_EXISTENT respectively.
301 #
302 # For example, given these settings:
303 #
304 # typeset -g POWERLEVEL9K_DIR_CLASSES=(
305 # '~/work(|/*)' WORK ''
306 # '~(|/*)' HOME ''
307 # '*' DEFAULT '')
308 #
309 # Whenever the current directory is ~/work or a subdirectory of ~/work, it gets styled with one
310 # of the following classes depending on its writability and existence: WORK, WORK_NOT_WRITABLE or
311 # WORK_NON_EXISTENT.
312 #
313 # Simply assigning classes to directories doesn't have any visible effects. It merely gives you an
314 # option to define custom colors and icons for different directory classes.
315 #
316 # # Styling for WORK.
317 # typeset -g POWERLEVEL9K_DIR_WORK_VISUAL_IDENTIFIER_EXPANSION='⭐'
318 # typeset -g POWERLEVEL9K_DIR_WORK_FOREGROUND=31
319 # typeset -g POWERLEVEL9K_DIR_WORK_SHORTENED_FOREGROUND=103
320 # typeset -g POWERLEVEL9K_DIR_WORK_ANCHOR_FOREGROUND=39
321 #
322 # # Styling for WORK_NOT_WRITABLE.
323 # typeset -g POWERLEVEL9K_DIR_WORK_NOT_WRITABLE_VISUAL_IDENTIFIER_EXPANSION='⭐'
324 # typeset -g POWERLEVEL9K_DIR_WORK_NOT_WRITABLE_FOREGROUND=31
325 # typeset -g POWERLEVEL9K_DIR_WORK_NOT_WRITABLE_SHORTENED_FOREGROUND=103
326 # typeset -g POWERLEVEL9K_DIR_WORK_NOT_WRITABLE_ANCHOR_FOREGROUND=39
327 #
328 # # Styling for WORK_NON_EXISTENT.
329 # typeset -g POWERLEVEL9K_DIR_WORK_NON_EXISTENT_VISUAL_IDENTIFIER_EXPANSION='⭐'
330 # typeset -g POWERLEVEL9K_DIR_WORK_NON_EXISTENT_FOREGROUND=31
331 # typeset -g POWERLEVEL9K_DIR_WORK_NON_EXISTENT_SHORTENED_FOREGROUND=103
332 # typeset -g POWERLEVEL9K_DIR_WORK_NON_EXISTENT_ANCHOR_FOREGROUND=39
333 #
334 # If a styling parameter isn't explicitly defined for some class, it falls back to the classless
335 # parameter. For example, if POWERLEVEL9K_DIR_WORK_NOT_WRITABLE_FOREGROUND is not set, it falls
336 # back to POWERLEVEL9K_DIR_FOREGROUND.
337 #
338 typeset -g POWERLEVEL9K_DIR_CLASSES=()
339
340 # Custom prefix.
341 # typeset -g POWERLEVEL9K_DIR_PREFIX='%fin '
342
343 #####################################[ vcs: git status ]######################################
344 # Branch icon. Set this parameter to '\uF126 ' for the popular Powerline branch icon.
345 typeset -g POWERLEVEL9K_VCS_BRANCH_ICON=
346
347 # Untracked files icon. It's really a question mark, your font isn't broken.
348 # Change the value of this parameter to show a different icon.
349 typeset -g POWERLEVEL9K_VCS_UNTRACKED_ICON='?'
350
351 # Formatter for Git status.
352 #
353 # Example output: master wip ⇣42⇡42 *42 merge ~42 +42 !42 ?42.
354 #
355 # You can edit the function to customize how Git status looks.
356 #
357 # VCS_STATUS_* parameters are set by gitstatus plugin. See reference:
358 # https://github.com/romkatv/gitstatus/blob/master/gitstatus.plugin.zsh.
359 function my_git_formatter() {
360 emulate -L zsh
361
362 if [[ -n $P9K_CONTENT ]]; then
363 # If P9K_CONTENT is not empty, use it. It's either "loading" or from vcs_info (not from
364 # gitstatus plugin). VCS_STATUS_* parameters are not available in this case.
365 typeset -g my_git_format=$P9K_CONTENT
366 return
367 fi
368
369 if (( $1 )); then
370 # Styling for up-to-date Git status.
371 local meta='%f' # default foreground
372 local clean='%76F' # green foreground
373 local modified='%178F' # yellow foreground
374 local untracked='%39F' # blue foreground
375 local conflicted='%196F' # red foreground
376 else
377 # Styling for incomplete and stale Git status.
378 local meta='%244F' # grey foreground
379 local clean='%244F' # grey foreground
380 local modified='%244F' # grey foreground
381 local untracked='%244F' # grey foreground
382 local conflicted='%244F' # grey foreground
383 fi
384
385 local res
386
387 if [[ -n $VCS_STATUS_LOCAL_BRANCH ]]; then
388 local branch=${(V)VCS_STATUS_LOCAL_BRANCH}
389 # If local branch name is at most 32 characters long, show it in full.
390 # Otherwise show the first 12 … the last 12.
391 # Tip: To always show local branch name in full without truncation, delete the next line.
392 (( $#branch > 32 )) && branch[13,-13]="…" # <-- this line
393 res+="${clean}${(g::)POWERLEVEL9K_VCS_BRANCH_ICON}${branch//\%/%%}"
394 fi
395
396 if [[ -n $VCS_STATUS_TAG
397 # Show tag only if not on a branch.
398 # Tip: To always show tag, delete the next line.
399 && -z $VCS_STATUS_LOCAL_BRANCH # <-- this line
400 ]]; then
401 local tag=${(V)VCS_STATUS_TAG}
402 # If tag name is at most 32 characters long, show it in full.
403 # Otherwise show the first 12 … the last 12.
404 # Tip: To always show tag name in full without truncation, delete the next line.
405 (( $#tag > 32 )) && tag[13,-13]="…" # <-- this line
406 res+="${meta}#${clean}${tag//\%/%%}"
407 fi
408
409 # Display the current Git commit if there is no branch and no tag.
410 # Tip: To always display the current Git commit, delete the next line.
411 [[ -z $VCS_STATUS_LOCAL_BRANCH && -z $VCS_STATUS_TAG ]] && # <-- this line
412 res+="${meta}@${clean}${VCS_STATUS_COMMIT[1,8]}"
413
414 # Show tracking branch name if it differs from local branch.
415 if [[ -n ${VCS_STATUS_REMOTE_BRANCH:#$VCS_STATUS_LOCAL_BRANCH} ]]; then
416 res+="${meta}:${clean}${(V)VCS_STATUS_REMOTE_BRANCH//\%/%%}"
417 fi
418
419 # Display "wip" if the latest commit's summary contains "wip" or "WIP".
420 if [[ $VCS_STATUS_COMMIT_SUMMARY == (|*[^[:alnum:]])(wip|WIP)(|[^[:alnum:]]*) ]]; then
421 res+=" ${modified}wip"
422 fi
423
424 # ⇣42 if behind the remote.
425 (( VCS_STATUS_COMMITS_BEHIND )) && res+=" ${clean}⇣${VCS_STATUS_COMMITS_BEHIND}"
426 # ⇡42 if ahead of the remote; no leading space if also behind the remote: ⇣42⇡42.
427 (( VCS_STATUS_COMMITS_AHEAD && !VCS_STATUS_COMMITS_BEHIND )) && res+=" "
428 (( VCS_STATUS_COMMITS_AHEAD )) && res+="${clean}⇡${VCS_STATUS_COMMITS_AHEAD}"
429 # ⇠42 if behind the push remote.
430 (( VCS_STATUS_PUSH_COMMITS_BEHIND )) && res+=" ${clean}⇠${VCS_STATUS_PUSH_COMMITS_BEHIND}"
431 (( VCS_STATUS_PUSH_COMMITS_AHEAD && !VCS_STATUS_PUSH_COMMITS_BEHIND )) && res+=" "
432 # ⇢42 if ahead of the push remote; no leading space if also behind: ⇠42⇢42.
433 (( VCS_STATUS_PUSH_COMMITS_AHEAD )) && res+="${clean}⇢${VCS_STATUS_PUSH_COMMITS_AHEAD}"
434 # *42 if have stashes.
435 (( VCS_STATUS_STASHES )) && res+=" ${clean}*${VCS_STATUS_STASHES}"
436 # 'merge' if the repo is in an unusual state.
437 [[ -n $VCS_STATUS_ACTION ]] && res+=" ${conflicted}${VCS_STATUS_ACTION}"
438 # ~42 if have merge conflicts.
439 (( VCS_STATUS_NUM_CONFLICTED )) && res+=" ${conflicted}~${VCS_STATUS_NUM_CONFLICTED}"
440 # +42 if have staged changes.
441 (( VCS_STATUS_NUM_STAGED )) && res+=" ${modified}+${VCS_STATUS_NUM_STAGED}"
442 # !42 if have unstaged changes.
443 (( VCS_STATUS_NUM_UNSTAGED )) && res+=" ${modified}!${VCS_STATUS_NUM_UNSTAGED}"
444 # ?42 if have untracked files. It's really a question mark, your font isn't broken.
445 # See POWERLEVEL9K_VCS_UNTRACKED_ICON above if you want to use a different icon.
446 # Remove the next line if you don't want to see untracked files at all.
447 (( VCS_STATUS_NUM_UNTRACKED )) && res+=" ${untracked}${(g::)POWERLEVEL9K_VCS_UNTRACKED_ICON}${VCS_STATUS_NUM_UNTRACKED}"
448 # "─" if the number of unstaged files is unknown. This can happen due to
449 # POWERLEVEL9K_VCS_MAX_INDEX_SIZE_DIRTY (see below) being set to a non-negative number lower
450 # than the number of files in the Git index, or due to bash.showDirtyState being set to false
451 # in the repository config. The number of staged and untracked files may also be unknown
452 # in this case.
453 (( VCS_STATUS_HAS_UNSTAGED == -1 )) && res+=" ${modified}─"
454
455 typeset -g my_git_format=$res
456 }
457 functions -M my_git_formatter 2>/dev/null
458
459 # Don't count the number of unstaged, untracked and conflicted files in Git repositories with
460 # more than this many files in the index. Negative value means infinity.
461 #
462 # If you are working in Git repositories with tens of millions of files and seeing performance
463 # sagging, try setting POWERLEVEL9K_VCS_MAX_INDEX_SIZE_DIRTY to a number lower than the output
464 # of `git ls-files | wc -l`. Alternatively, add `bash.showDirtyState = false` to the repository's
465 # config: `git config bash.showDirtyState false`.
466 typeset -g POWERLEVEL9K_VCS_MAX_INDEX_SIZE_DIRTY=-1
467
468 # Don't show Git status in prompt for repositories whose workdir matches this pattern.
469 # For example, if set to '~', the Git repository at $HOME/.git will be ignored.
470 # Multiple patterns can be combined with '|': '~(|/foo)|/bar/baz/*'.
471 typeset -g POWERLEVEL9K_VCS_DISABLED_WORKDIR_PATTERN='~'
472
473 # Disable the default Git status formatting.
474 typeset -g POWERLEVEL9K_VCS_DISABLE_GITSTATUS_FORMATTING=true
475 # Install our own Git status formatter.
476 typeset -g POWERLEVEL9K_VCS_CONTENT_EXPANSION='${$((my_git_formatter(1)))+${my_git_format}}'
477 typeset -g POWERLEVEL9K_VCS_LOADING_CONTENT_EXPANSION='${$((my_git_formatter(0)))+${my_git_format}}'
478 # Enable counters for staged, unstaged, etc.
479 typeset -g POWERLEVEL9K_VCS_{STAGED,UNSTAGED,UNTRACKED,CONFLICTED,COMMITS_AHEAD,COMMITS_BEHIND}_MAX_NUM=-1
480
481 # Icon color.
482 typeset -g POWERLEVEL9K_VCS_VISUAL_IDENTIFIER_COLOR=76
483 typeset -g POWERLEVEL9K_VCS_LOADING_VISUAL_IDENTIFIER_COLOR=244
484 # Custom icon.
485 typeset -g POWERLEVEL9K_VCS_VISUAL_IDENTIFIER_EXPANSION=
486 # Custom prefix.
487 # typeset -g POWERLEVEL9K_VCS_PREFIX='%fon '
488
489 # Show status of repositories of these types. You can add svn and/or hg if you are
490 # using them. If you do, your prompt may become slow even when your current directory
491 # isn't in an svn or hg reposotiry.
492 typeset -g POWERLEVEL9K_VCS_BACKENDS=(git)
493
494 # These settings are used for repositories other than Git or when gitstatusd fails and
495 # Powerlevel10k has to fall back to using vcs_info.
496 typeset -g POWERLEVEL9K_VCS_CLEAN_FOREGROUND=76
497 typeset -g POWERLEVEL9K_VCS_UNTRACKED_FOREGROUND=76
498 typeset -g POWERLEVEL9K_VCS_MODIFIED_FOREGROUND=178
499
500 ##########################[ status: exit code of the last command ]###########################
501 # Enable OK_PIPE, ERROR_PIPE and ERROR_SIGNAL status states to allow us to enable, disable and
502 # style them independently from the regular OK and ERROR state.
503 typeset -g POWERLEVEL9K_STATUS_EXTENDED_STATES=true
504
505 # Status on success. No content, just an icon. No need to show it if prompt_char is enabled as
506 # it will signify success by turning green.
507 typeset -g POWERLEVEL9K_STATUS_OK=false
508 typeset -g POWERLEVEL9K_STATUS_OK_FOREGROUND=70
509 typeset -g POWERLEVEL9K_STATUS_OK_VISUAL_IDENTIFIER_EXPANSION='✔'
510
511 # Status when some part of a pipe command fails but the overall exit status is zero. It may look
512 # like this: 1|0.
513 typeset -g POWERLEVEL9K_STATUS_OK_PIPE=true
514 typeset -g POWERLEVEL9K_STATUS_OK_PIPE_FOREGROUND=70
515 typeset -g POWERLEVEL9K_STATUS_OK_PIPE_VISUAL_IDENTIFIER_EXPANSION='✔'
516
517 # Status when it's just an error code (e.g., '1'). No need to show it if prompt_char is enabled as
518 # it will signify error by turning red.
519 typeset -g POWERLEVEL9K_STATUS_ERROR=false
520 typeset -g POWERLEVEL9K_STATUS_ERROR_FOREGROUND=160
521 typeset -g POWERLEVEL9K_STATUS_ERROR_VISUAL_IDENTIFIER_EXPANSION='✘'
522
523 # Status when the last command was terminated by a signal.
524 typeset -g POWERLEVEL9K_STATUS_ERROR_SIGNAL=true
525 typeset -g POWERLEVEL9K_STATUS_ERROR_SIGNAL_FOREGROUND=160
526 # Use terse signal names: "INT" instead of "SIGINT(2)".
527 typeset -g POWERLEVEL9K_STATUS_VERBOSE_SIGNAME=false
528 typeset -g POWERLEVEL9K_STATUS_ERROR_SIGNAL_VISUAL_IDENTIFIER_EXPANSION='✘'
529
530 # Status when some part of a pipe command fails and the overall exit status is also non-zero.
531 # It may look like this: 1|0.
532 typeset -g POWERLEVEL9K_STATUS_ERROR_PIPE=true
533 typeset -g POWERLEVEL9K_STATUS_ERROR_PIPE_FOREGROUND=160
534 typeset -g POWERLEVEL9K_STATUS_ERROR_PIPE_VISUAL_IDENTIFIER_EXPANSION='✘'
535
536 ###################[ command_execution_time: duration of the last command ]###################
537 # Show duration of the last command if takes at least this many seconds.
538 typeset -g POWERLEVEL9K_COMMAND_EXECUTION_TIME_THRESHOLD=3
539 # Show this many fractional digits. Zero means round to seconds.
540 typeset -g POWERLEVEL9K_COMMAND_EXECUTION_TIME_PRECISION=0
541 # Execution time color.
542 typeset -g POWERLEVEL9K_COMMAND_EXECUTION_TIME_FOREGROUND=101
543 # Duration format: 1d 2h 3m 4s.
544 typeset -g POWERLEVEL9K_COMMAND_EXECUTION_TIME_FORMAT='d h m s'
545 # Custom icon.
546 typeset -g POWERLEVEL9K_COMMAND_EXECUTION_TIME_VISUAL_IDENTIFIER_EXPANSION=
547 # Custom prefix.
548 # typeset -g POWERLEVEL9K_COMMAND_EXECUTION_TIME_PREFIX='%ftook '
549
550 #######################[ background_jobs: presence of background jobs ]#######################
551 # Don't show the number of background jobs.
552 typeset -g POWERLEVEL9K_BACKGROUND_JOBS_VERBOSE=false
553 # Background jobs color.
554 typeset -g POWERLEVEL9K_BACKGROUND_JOBS_FOREGROUND=70
555 # Custom icon.
556 # typeset -g POWERLEVEL9K_BACKGROUND_JOBS_VISUAL_IDENTIFIER_EXPANSION='⭐'
557
558 #######################[ direnv: direnv status (https://direnv.net/) ]########################
559 # Direnv color.
560 typeset -g POWERLEVEL9K_DIRENV_FOREGROUND=178
561 # Custom icon.
562 # typeset -g POWERLEVEL9K_DIRENV_VISUAL_IDENTIFIER_EXPANSION='⭐'
563
564 ###############[ asdf: asdf version manager (https://github.com/asdf-vm/asdf) ]###############
565 # Default asdf color. Only used to display tools for which there is no color override (see below).
566 # Tip: Override this parameter for ${TOOL} with POWERLEVEL9K_ASDF_${TOOL}_FOREGROUND.
567 typeset -g POWERLEVEL9K_ASDF_FOREGROUND=66
568
569 # There are four parameters that can be used to hide asdf tools. Each parameter describes
570 # conditions under which a tool gets hidden. Parameters can hide tools but not unhide them. If at
571 # least one parameter decides to hide a tool, that tool gets hidden. If no parameter decides to
572 # hide a tool, it gets shown.
573 #
574 # Special note on the difference between POWERLEVEL9K_ASDF_SOURCES and
575 # POWERLEVEL9K_ASDF_PROMPT_ALWAYS_SHOW. Consider the effect of the following commands:
576 #
577 # asdf local python 3.8.1
578 # asdf global python 3.8.1
579 #
580 # After running both commands the current python version is 3.8.1 and its source is "local" as
581 # it takes precedence over "global". If POWERLEVEL9K_ASDF_PROMPT_ALWAYS_SHOW is set to false,
582 # it'll hide python version in this case because 3.8.1 is the same as the global version.
583 # POWERLEVEL9K_ASDF_SOURCES will hide python version only if the value of this parameter doesn't
584 # contain "local".
585
586 # Hide tool versions that don't come from one of these sources.
587 #
588 # Available sources:
589 #
590 # - shell `asdf current` says "set by ASDF_${TOOL}_VERSION environment variable"
591 # - local `asdf current` says "set by /some/not/home/directory/file"
592 # - global `asdf current` says "set by /home/username/file"
593 #
594 # Note: If this parameter is set to (shell local global), it won't hide tools.
595 # Tip: Override this parameter for ${TOOL} with POWERLEVEL9K_ASDF_${TOOL}_SOURCES.
596 typeset -g POWERLEVEL9K_ASDF_SOURCES=(shell local global)
597
598 # If set to false, hide tool versions that are the same as global.
599 #
600 # Note: The name of this parameter doesn't reflect its meaning at all.
601 # Note: If this parameter is set to true, it won't hide tools.
602 # Tip: Override this parameter for ${TOOL} with POWERLEVEL9K_ASDF_${TOOL}_PROMPT_ALWAYS_SHOW.
603 typeset -g POWERLEVEL9K_ASDF_PROMPT_ALWAYS_SHOW=false
604
605 # If set to false, hide tool versions that are equal to "system".
606 #
607 # Note: If this parameter is set to true, it won't hide tools.
608 # Tip: Override this parameter for ${TOOL} with POWERLEVEL9K_ASDF_${TOOL}_SHOW_SYSTEM.
609 typeset -g POWERLEVEL9K_ASDF_SHOW_SYSTEM=true
610
611 # If set to non-empty value, hide tools unless there is a file matching the specified file pattern
612 # in the current directory, or its parent directory, or its grandparent directory, and so on.
613 #
614 # Note: If this parameter is set to empty value, it won't hide tools.
615 # Note: SHOW_ON_UPGLOB isn't specific to asdf. It works with all prompt segments.
616 # Tip: Override this parameter for ${TOOL} with POWERLEVEL9K_ASDF_${TOOL}_SHOW_ON_UPGLOB.
617 #
618 # Example: Hide nodejs version when there is no package.json and no *.js files in the current
619 # directory, in `..`, in `../..` and so on.
620 #
621 # typeset -g POWERLEVEL9K_ASDF_NODEJS_SHOW_ON_UPGLOB='*.js|package.json'
622 typeset -g POWERLEVEL9K_ASDF_SHOW_ON_UPGLOB=
623
624 # Ruby version from asdf.
625 typeset -g POWERLEVEL9K_ASDF_RUBY_FOREGROUND=168
626 # typeset -g POWERLEVEL9K_ASDF_RUBY_VISUAL_IDENTIFIER_EXPANSION='⭐'
627 # typeset -g POWERLEVEL9K_ASDF_RUBY_SHOW_ON_UPGLOB='*.foo|*.bar'
628
629 # Python version from asdf.
630 typeset -g POWERLEVEL9K_ASDF_PYTHON_FOREGROUND=37
631 # typeset -g POWERLEVEL9K_ASDF_PYTHON_VISUAL_IDENTIFIER_EXPANSION='⭐'
632 # typeset -g POWERLEVEL9K_ASDF_PYTHON_SHOW_ON_UPGLOB='*.foo|*.bar'
633
634 # Go version from asdf.
635 typeset -g POWERLEVEL9K_ASDF_GOLANG_FOREGROUND=37
636 # typeset -g POWERLEVEL9K_ASDF_GOLANG_VISUAL_IDENTIFIER_EXPANSION='⭐'
637 # typeset -g POWERLEVEL9K_ASDF_GOLANG_SHOW_ON_UPGLOB='*.foo|*.bar'
638
639 # Node.js version from asdf.
640 typeset -g POWERLEVEL9K_ASDF_NODEJS_FOREGROUND=70
641 # typeset -g POWERLEVEL9K_ASDF_NODEJS_VISUAL_IDENTIFIER_EXPANSION='⭐'
642 # typeset -g POWERLEVEL9K_ASDF_NODEJS_SHOW_ON_UPGLOB='*.foo|*.bar'
643
644 # Rust version from asdf.
645 typeset -g POWERLEVEL9K_ASDF_RUST_FOREGROUND=37
646 # typeset -g POWERLEVEL9K_ASDF_RUST_VISUAL_IDENTIFIER_EXPANSION='⭐'
647 # typeset -g POWERLEVEL9K_ASDF_RUST_SHOW_ON_UPGLOB='*.foo|*.bar'
648
649 # .NET Core version from asdf.
650 typeset -g POWERLEVEL9K_ASDF_DOTNET_CORE_FOREGROUND=134
651 # typeset -g POWERLEVEL9K_ASDF_DOTNET_CORE_VISUAL_IDENTIFIER_EXPANSION='⭐'
652 # typeset -g POWERLEVEL9K_ASDF_DOTNET_SHOW_ON_UPGLOB='*.foo|*.bar'
653
654 # Flutter version from asdf.
655 typeset -g POWERLEVEL9K_ASDF_FLUTTER_FOREGROUND=38
656 # typeset -g POWERLEVEL9K_ASDF_FLUTTER_VISUAL_IDENTIFIER_EXPANSION='⭐'
657 # typeset -g POWERLEVEL9K_ASDF_FLUTTER_SHOW_ON_UPGLOB='*.foo|*.bar'
658
659 # Lua version from asdf.
660 typeset -g POWERLEVEL9K_ASDF_LUA_FOREGROUND=32
661 # typeset -g POWERLEVEL9K_ASDF_LUA_VISUAL_IDENTIFIER_EXPANSION='⭐'
662 # typeset -g POWERLEVEL9K_ASDF_LUA_SHOW_ON_UPGLOB='*.foo|*.bar'
663
664 # Java version from asdf.
665 typeset -g POWERLEVEL9K_ASDF_JAVA_FOREGROUND=32
666 # typeset -g POWERLEVEL9K_ASDF_JAVA_VISUAL_IDENTIFIER_EXPANSION='⭐'
667 # typeset -g POWERLEVEL9K_ASDF_JAVA_SHOW_ON_UPGLOB='*.foo|*.bar'
668
669 # Perl version from asdf.
670 typeset -g POWERLEVEL9K_ASDF_PERL_FOREGROUND=67
671 # typeset -g POWERLEVEL9K_ASDF_PERL_VISUAL_IDENTIFIER_EXPANSION='⭐'
672 # typeset -g POWERLEVEL9K_ASDF_PERL_SHOW_ON_UPGLOB='*.foo|*.bar'
673
674 # Erlang version from asdf.
675 typeset -g POWERLEVEL9K_ASDF_ERLANG_FOREGROUND=125
676 # typeset -g POWERLEVEL9K_ASDF_ERLANG_VISUAL_IDENTIFIER_EXPANSION='⭐'
677 # typeset -g POWERLEVEL9K_ASDF_ERLANG_SHOW_ON_UPGLOB='*.foo|*.bar'
678
679 # Elixir version from asdf.
680 typeset -g POWERLEVEL9K_ASDF_ELIXIR_FOREGROUND=129
681 # typeset -g POWERLEVEL9K_ASDF_ELIXIR_VISUAL_IDENTIFIER_EXPANSION='⭐'
682 # typeset -g POWERLEVEL9K_ASDF_ELIXIR_SHOW_ON_UPGLOB='*.foo|*.bar'
683
684 # Postgres version from asdf.
685 typeset -g POWERLEVEL9K_ASDF_POSTGRES_FOREGROUND=31
686 # typeset -g POWERLEVEL9K_ASDF_POSTGRES_VISUAL_IDENTIFIER_EXPANSION='⭐'
687 # typeset -g POWERLEVEL9K_ASDF_POSTGRES_SHOW_ON_UPGLOB='*.foo|*.bar'
688
689 # PHP version from asdf.
690 typeset -g POWERLEVEL9K_ASDF_PHP_FOREGROUND=99
691 # typeset -g POWERLEVEL9K_ASDF_PHP_VISUAL_IDENTIFIER_EXPANSION='⭐'
692 # typeset -g POWERLEVEL9K_ASDF_PHP_SHOW_ON_UPGLOB='*.foo|*.bar'
693
694 # Haskell version from asdf.
695 typeset -g POWERLEVEL9K_ASDF_HASKELL_FOREGROUND=172
696 # typeset -g POWERLEVEL9K_ASDF_HASKELL_VISUAL_IDENTIFIER_EXPANSION='⭐'
697 # typeset -g POWERLEVEL9K_ASDF_HASKELL_SHOW_ON_UPGLOB='*.foo|*.bar'
698
699 # Julia version from asdf.
700 typeset -g POWERLEVEL9K_ASDF_JULIA_FOREGROUND=70
701 # typeset -g POWERLEVEL9K_ASDF_JULIA_VISUAL_IDENTIFIER_EXPANSION='⭐'
702 # typeset -g POWERLEVEL9K_ASDF_JULIA_SHOW_ON_UPGLOB='*.foo|*.bar'
703
704 ##########[ nordvpn: nordvpn connection status, linux only (https://nordvpn.com/) ]###########
705 # NordVPN connection indicator color.
706 typeset -g POWERLEVEL9K_NORDVPN_FOREGROUND=39
707 # Hide NordVPN connection indicator when not connected.
708 typeset -g POWERLEVEL9K_NORDVPN_{DISCONNECTED,CONNECTING,DISCONNECTING}_CONTENT_EXPANSION=
709 typeset -g POWERLEVEL9K_NORDVPN_{DISCONNECTED,CONNECTING,DISCONNECTING}_VISUAL_IDENTIFIER_EXPANSION=
710 # Custom icon.
711 # typeset -g POWERLEVEL9K_NORDVPN_VISUAL_IDENTIFIER_EXPANSION='⭐'
712
713 #################[ ranger: ranger shell (https://github.com/ranger/ranger) ]##################
714 # Ranger shell color.
715 typeset -g POWERLEVEL9K_RANGER_FOREGROUND=178
716 # Custom icon.
717 # typeset -g POWERLEVEL9K_RANGER_VISUAL_IDENTIFIER_EXPANSION='⭐'
718
719 ######################[ nnn: nnn shell (https://github.com/jarun/nnn) ]#######################
720 # Nnn shell color.
721 typeset -g POWERLEVEL9K_NNN_FOREGROUND=72
722 # Custom icon.
723 # typeset -g POWERLEVEL9K_NNN_VISUAL_IDENTIFIER_EXPANSION='⭐'
724
725 ##################[ xplr: xplr shell (https://github.com/sayanarijit/xplr) ]##################
726 # xplr shell color.
727 typeset -g POWERLEVEL9K_XPLR_FOREGROUND=72
728 # Custom icon.
729 # typeset -g POWERLEVEL9K_XPLR_VISUAL_IDENTIFIER_EXPANSION='⭐'
730
731 ###########################[ vim_shell: vim shell indicator (:sh) ]###########################
732 # Vim shell indicator color.
733 typeset -g POWERLEVEL9K_VIM_SHELL_FOREGROUND=34
734 # Custom icon.
735 # typeset -g POWERLEVEL9K_VIM_SHELL_VISUAL_IDENTIFIER_EXPANSION='⭐'
736
737 ######[ midnight_commander: midnight commander shell (https://midnight-commander.org/) ]######
738 # Midnight Commander shell color.
739 typeset -g POWERLEVEL9K_MIDNIGHT_COMMANDER_FOREGROUND=178
740 # Custom icon.
741 # typeset -g POWERLEVEL9K_MIDNIGHT_COMMANDER_VISUAL_IDENTIFIER_EXPANSION='⭐'
742
743 #[ nix_shell: nix shell (https://nixos.org/nixos/nix-pills/developing-with-nix-shell.html) ]##
744 # Nix shell color.
745 typeset -g POWERLEVEL9K_NIX_SHELL_FOREGROUND=74
746
747 # Tip: If you want to see just the icon without "pure" and "impure", uncomment the next line.
748 # typeset -g POWERLEVEL9K_NIX_SHELL_CONTENT_EXPANSION=
749
750 # Custom icon.
751 # typeset -g POWERLEVEL9K_NIX_SHELL_VISUAL_IDENTIFIER_EXPANSION='⭐'
752
753 ##################################[ disk_usage: disk usage ]##################################
754 # Colors for different levels of disk usage.
755 typeset -g POWERLEVEL9K_DISK_USAGE_NORMAL_FOREGROUND=35
756 typeset -g POWERLEVEL9K_DISK_USAGE_WARNING_FOREGROUND=220
757 typeset -g POWERLEVEL9K_DISK_USAGE_CRITICAL_FOREGROUND=160
758 # Thresholds for different levels of disk usage (percentage points).
759 typeset -g POWERLEVEL9K_DISK_USAGE_WARNING_LEVEL=90
760 typeset -g POWERLEVEL9K_DISK_USAGE_CRITICAL_LEVEL=95
761 # If set to true, hide disk usage when below $POWERLEVEL9K_DISK_USAGE_WARNING_LEVEL percent.
762 typeset -g POWERLEVEL9K_DISK_USAGE_ONLY_WARNING=false
763 # Custom icon.
764 # typeset -g POWERLEVEL9K_DISK_USAGE_VISUAL_IDENTIFIER_EXPANSION='⭐'
765
766 ######################################[ ram: free RAM ]#######################################
767 # RAM color.
768 typeset -g POWERLEVEL9K_RAM_FOREGROUND=66
769 # Custom icon.
770 # typeset -g POWERLEVEL9K_RAM_VISUAL_IDENTIFIER_EXPANSION='⭐'
771
772 #####################################[ swap: used swap ]######################################
773 # Swap color.
774 typeset -g POWERLEVEL9K_SWAP_FOREGROUND=96
775 # Custom icon.
776 # typeset -g POWERLEVEL9K_SWAP_VISUAL_IDENTIFIER_EXPANSION='⭐'
777
778 ######################################[ load: CPU load ]######################################
779 # Show average CPU load over this many last minutes. Valid values are 1, 5 and 15.
780 typeset -g POWERLEVEL9K_LOAD_WHICH=5
781 # Load color when load is under 50%.
782 typeset -g POWERLEVEL9K_LOAD_NORMAL_FOREGROUND=66
783 # Load color when load is between 50% and 70%.
784 typeset -g POWERLEVEL9K_LOAD_WARNING_FOREGROUND=178
785 # Load color when load is over 70%.
786 typeset -g POWERLEVEL9K_LOAD_CRITICAL_FOREGROUND=166
787 # Custom icon.
788 # typeset -g POWERLEVEL9K_LOAD_VISUAL_IDENTIFIER_EXPANSION='⭐'
789
790 ################[ todo: todo items (https://github.com/todotxt/todo.txt-cli) ]################
791 # Todo color.
792 typeset -g POWERLEVEL9K_TODO_FOREGROUND=110
793 # Hide todo when the total number of tasks is zero.
794 typeset -g POWERLEVEL9K_TODO_HIDE_ZERO_TOTAL=true
795 # Hide todo when the number of tasks after filtering is zero.
796 typeset -g POWERLEVEL9K_TODO_HIDE_ZERO_FILTERED=false
797
798 # Todo format. The following parameters are available within the expansion.
799 #
800 # - P9K_TODO_TOTAL_TASK_COUNT The total number of tasks.
801 # - P9K_TODO_FILTERED_TASK_COUNT The number of tasks after filtering.
802 #
803 # These variables correspond to the last line of the output of `todo.sh -p ls`:
804 #
805 # TODO: 24 of 42 tasks shown
806 #
807 # Here 24 is P9K_TODO_FILTERED_TASK_COUNT and 42 is P9K_TODO_TOTAL_TASK_COUNT.
808 #
809 # typeset -g POWERLEVEL9K_TODO_CONTENT_EXPANSION='$P9K_TODO_FILTERED_TASK_COUNT'
810
811 # Custom icon.
812 # typeset -g POWERLEVEL9K_TODO_VISUAL_IDENTIFIER_EXPANSION='⭐'
813
814 ###########[ timewarrior: timewarrior tracking status (https://timewarrior.net/) ]############
815 # Timewarrior color.
816 typeset -g POWERLEVEL9K_TIMEWARRIOR_FOREGROUND=110
817 # If the tracked task is longer than 24 characters, truncate and append "…".
818 # Tip: To always display tasks without truncation, delete the following parameter.
819 # Tip: To hide task names and display just the icon when time tracking is enabled, set the
820 # value of the following parameter to "".
821 typeset -g POWERLEVEL9K_TIMEWARRIOR_CONTENT_EXPANSION='${P9K_CONTENT:0:24}${${P9K_CONTENT:24}:+…}'
822
823 # Custom icon.
824 # typeset -g POWERLEVEL9K_TIMEWARRIOR_VISUAL_IDENTIFIER_EXPANSION='⭐'
825
826 ##############[ taskwarrior: taskwarrior task count (https://taskwarrior.org/) ]##############
827 # Taskwarrior color.
828 typeset -g POWERLEVEL9K_TASKWARRIOR_FOREGROUND=74
829
830 # Taskwarrior segment format. The following parameters are available within the expansion.
831 #
832 # - P9K_TASKWARRIOR_PENDING_COUNT The number of pending tasks: `task +PENDING count`.
833 # - P9K_TASKWARRIOR_OVERDUE_COUNT The number of overdue tasks: `task +OVERDUE count`.
834 #
835 # Zero values are represented as empty parameters.
836 #
837 # The default format:
838 #
839 # '${P9K_TASKWARRIOR_OVERDUE_COUNT:+"!$P9K_TASKWARRIOR_OVERDUE_COUNT/"}$P9K_TASKWARRIOR_PENDING_COUNT'
840 #
841 # typeset -g POWERLEVEL9K_TASKWARRIOR_CONTENT_EXPANSION='$P9K_TASKWARRIOR_PENDING_COUNT'
842
843 # Custom icon.
844 # typeset -g POWERLEVEL9K_TASKWARRIOR_VISUAL_IDENTIFIER_EXPANSION='⭐'
845
846 ##################################[ context: user@hostname ]##################################
847 # Context color when running with privileges.
848 typeset -g POWERLEVEL9K_CONTEXT_ROOT_FOREGROUND=178
849 # Context color in SSH without privileges.
850 typeset -g POWERLEVEL9K_CONTEXT_{REMOTE,REMOTE_SUDO}_FOREGROUND=180
851 # Default context color (no privileges, no SSH).
852 typeset -g POWERLEVEL9K_CONTEXT_FOREGROUND=180
853
854 # Context format when running with privileges: bold user@hostname.
855 typeset -g POWERLEVEL9K_CONTEXT_ROOT_TEMPLATE='%B%n@%m'
856 # Context format when in SSH without privileges: user@hostname.
857 typeset -g POWERLEVEL9K_CONTEXT_{REMOTE,REMOTE_SUDO}_TEMPLATE='%n@%m'
858 # Default context format (no privileges, no SSH): user@hostname.
859 typeset -g POWERLEVEL9K_CONTEXT_TEMPLATE='%n@%m'
860
861 # Don't show context unless running with privileges or in SSH.
862 # Tip: Remove the next line to always show context.
863 typeset -g POWERLEVEL9K_CONTEXT_{DEFAULT,SUDO}_{CONTENT,VISUAL_IDENTIFIER}_EXPANSION=
864
865 # Custom icon.
866 # typeset -g POWERLEVEL9K_CONTEXT_VISUAL_IDENTIFIER_EXPANSION='⭐'
867 # Custom prefix.
868 # typeset -g POWERLEVEL9K_CONTEXT_PREFIX='%fwith '
869
870 ###[ virtualenv: python virtual environment (https://docs.python.org/3/library/venv.html) ]###
871 # Python virtual environment color.
872 typeset -g POWERLEVEL9K_VIRTUALENV_FOREGROUND=37
873 # Don't show Python version next to the virtual environment name.
874 typeset -g POWERLEVEL9K_VIRTUALENV_SHOW_PYTHON_VERSION=false
875 # If set to "false", won't show virtualenv if pyenv is already shown.
876 # If set to "if-different", won't show virtualenv if it's the same as pyenv.
877 typeset -g POWERLEVEL9K_VIRTUALENV_SHOW_WITH_PYENV=false
878 # Separate environment name from Python version only with a space.
879 typeset -g POWERLEVEL9K_VIRTUALENV_{LEFT,RIGHT}_DELIMITER=
880 # Custom icon.
881 # typeset -g POWERLEVEL9K_VIRTUALENV_VISUAL_IDENTIFIER_EXPANSION='⭐'
882
883 #####################[ anaconda: conda environment (https://conda.io/) ]######################
884 # Anaconda environment color.
885 typeset -g POWERLEVEL9K_ANACONDA_FOREGROUND=37
886
887 # Anaconda segment format. The following parameters are available within the expansion.
888 #
889 # - CONDA_PREFIX Absolute path to the active Anaconda/Miniconda environment.
890 # - CONDA_DEFAULT_ENV Name of the active Anaconda/Miniconda environment.
891 # - CONDA_PROMPT_MODIFIER Configurable prompt modifier (see below).
892 # - P9K_ANACONDA_PYTHON_VERSION Current python version (python --version).
893 #
894 # CONDA_PROMPT_MODIFIER can be configured with the following command:
895 #
896 # conda config --set env_prompt '({default_env}) '
897 #
898 # The last argument is a Python format string that can use the following variables:
899 #
900 # - prefix The same as CONDA_PREFIX.
901 # - default_env The same as CONDA_DEFAULT_ENV.
902 # - name The last segment of CONDA_PREFIX.
903 # - stacked_env Comma-separated list of names in the environment stack. The first element is
904 # always the same as default_env.
905 #
906 # Note: '({default_env}) ' is the default value of env_prompt.
907 #
908 # The default value of POWERLEVEL9K_ANACONDA_CONTENT_EXPANSION expands to $CONDA_PROMPT_MODIFIER
909 # without the surrounding parentheses, or to the last path component of CONDA_PREFIX if the former
910 # is empty.
911 typeset -g POWERLEVEL9K_ANACONDA_CONTENT_EXPANSION='${${${${CONDA_PROMPT_MODIFIER#\(}% }%\)}:-${CONDA_PREFIX:t}}'
912
913 # Custom icon.
914 # typeset -g POWERLEVEL9K_ANACONDA_VISUAL_IDENTIFIER_EXPANSION='⭐'
915
916 ################[ pyenv: python environment (https://github.com/pyenv/pyenv) ]################
917 # Pyenv color.
918 typeset -g POWERLEVEL9K_PYENV_FOREGROUND=37
919 # Hide python version if it doesn't come from one of these sources.
920 typeset -g POWERLEVEL9K_PYENV_SOURCES=(shell local global)
921 # If set to false, hide python version if it's the same as global:
922 # $(pyenv version-name) == $(pyenv global).
923 typeset -g POWERLEVEL9K_PYENV_PROMPT_ALWAYS_SHOW=false
924 # If set to false, hide python version if it's equal to "system".
925 typeset -g POWERLEVEL9K_PYENV_SHOW_SYSTEM=true
926
927 # Pyenv segment format. The following parameters are available within the expansion.
928 #
929 # - P9K_CONTENT Current pyenv environment (pyenv version-name).
930 # - P9K_PYENV_PYTHON_VERSION Current python version (python --version).
931 #
932 # The default format has the following logic:
933 #
934 # 1. Display just "$P9K_CONTENT" if it's equal to "$P9K_PYENV_PYTHON_VERSION" or
935 # starts with "$P9K_PYENV_PYTHON_VERSION/".
936 # 2. Otherwise display "$P9K_CONTENT $P9K_PYENV_PYTHON_VERSION".
937 typeset -g POWERLEVEL9K_PYENV_CONTENT_EXPANSION='${P9K_CONTENT}${${P9K_CONTENT:#$P9K_PYENV_PYTHON_VERSION(|/*)}:+ $P9K_PYENV_PYTHON_VERSION}'
938
939 # Custom icon.
940 # typeset -g POWERLEVEL9K_PYENV_VISUAL_IDENTIFIER_EXPANSION='⭐'
941
942 ################[ goenv: go environment (https://github.com/syndbg/goenv) ]################
943 # Goenv color.
944 typeset -g POWERLEVEL9K_GOENV_FOREGROUND=37
945 # Hide go version if it doesn't come from one of these sources.
946 typeset -g POWERLEVEL9K_GOENV_SOURCES=(shell local global)
947 # If set to false, hide go version if it's the same as global:
948 # $(goenv version-name) == $(goenv global).
949 typeset -g POWERLEVEL9K_GOENV_PROMPT_ALWAYS_SHOW=false
950 # If set to false, hide go version if it's equal to "system".
951 typeset -g POWERLEVEL9K_GOENV_SHOW_SYSTEM=true
952 # Custom icon.
953 # typeset -g POWERLEVEL9K_GOENV_VISUAL_IDENTIFIER_EXPANSION='⭐'
954
955 ##########[ nodenv: node.js version from nodenv (https://github.com/nodenv/nodenv) ]##########
956 # Nodenv color.
957 typeset -g POWERLEVEL9K_NODENV_FOREGROUND=70
958 # Hide node version if it doesn't come from one of these sources.
959 typeset -g POWERLEVEL9K_NODENV_SOURCES=(shell local global)
960 # If set to false, hide node version if it's the same as global:
961 # $(nodenv version-name) == $(nodenv global).
962 typeset -g POWERLEVEL9K_NODENV_PROMPT_ALWAYS_SHOW=false
963 # If set to false, hide node version if it's equal to "system".
964 typeset -g POWERLEVEL9K_NODENV_SHOW_SYSTEM=true
965 # Custom icon.
966 # typeset -g POWERLEVEL9K_NODENV_VISUAL_IDENTIFIER_EXPANSION='⭐'
967
968 ##############[ nvm: node.js version from nvm (https://github.com/nvm-sh/nvm) ]###############
969 # Nvm color.
970 typeset -g POWERLEVEL9K_NVM_FOREGROUND=70
971 # Custom icon.
972 # typeset -g POWERLEVEL9K_NVM_VISUAL_IDENTIFIER_EXPANSION='⭐'
973
974 ############[ nodeenv: node.js environment (https://github.com/ekalinin/nodeenv) ]############
975 # Nodeenv color.
976 typeset -g POWERLEVEL9K_NODEENV_FOREGROUND=70
977 # Don't show Node version next to the environment name.
978 typeset -g POWERLEVEL9K_NODEENV_SHOW_NODE_VERSION=false
979 # Separate environment name from Node version only with a space.
980 typeset -g POWERLEVEL9K_NODEENV_{LEFT,RIGHT}_DELIMITER=
981 # Custom icon.
982 # typeset -g POWERLEVEL9K_NODEENV_VISUAL_IDENTIFIER_EXPANSION='⭐'
983
984 ##############################[ node_version: node.js version ]###############################
985 # Node version color.
986 typeset -g POWERLEVEL9K_NODE_VERSION_FOREGROUND=70
987 # Show node version only when in a directory tree containing package.json.
988 typeset -g POWERLEVEL9K_NODE_VERSION_PROJECT_ONLY=true
989 # Custom icon.
990 # typeset -g POWERLEVEL9K_NODE_VERSION_VISUAL_IDENTIFIER_EXPANSION='⭐'
991
992 #######################[ go_version: go version (https://golang.org) ]########################
993 # Go version color.
994 typeset -g POWERLEVEL9K_GO_VERSION_FOREGROUND=37
995 # Show go version only when in a go project subdirectory.
996 typeset -g POWERLEVEL9K_GO_VERSION_PROJECT_ONLY=true
997 # Custom icon.
998 # typeset -g POWERLEVEL9K_GO_VERSION_VISUAL_IDENTIFIER_EXPANSION='⭐'
999
1000 #################[ rust_version: rustc version (https://www.rust-lang.org) ]##################
1001 # Rust version color.
1002 typeset -g POWERLEVEL9K_RUST_VERSION_FOREGROUND=37
1003 # Show rust version only when in a rust project subdirectory.
1004 typeset -g POWERLEVEL9K_RUST_VERSION_PROJECT_ONLY=true
1005 # Custom icon.
1006 # typeset -g POWERLEVEL9K_RUST_VERSION_VISUAL_IDENTIFIER_EXPANSION='⭐'
1007
1008 ###############[ dotnet_version: .NET version (https://dotnet.microsoft.com) ]################
1009 # .NET version color.
1010 typeset -g POWERLEVEL9K_DOTNET_VERSION_FOREGROUND=134
1011 # Show .NET version only when in a .NET project subdirectory.
1012 typeset -g POWERLEVEL9K_DOTNET_VERSION_PROJECT_ONLY=true
1013 # Custom icon.
1014 # typeset -g POWERLEVEL9K_DOTNET_VERSION_VISUAL_IDENTIFIER_EXPANSION='⭐'
1015
1016 #####################[ php_version: php version (https://www.php.net/) ]######################
1017 # PHP version color.
1018 typeset -g POWERLEVEL9K_PHP_VERSION_FOREGROUND=99
1019 # Show PHP version only when in a PHP project subdirectory.
1020 typeset -g POWERLEVEL9K_PHP_VERSION_PROJECT_ONLY=true
1021 # Custom icon.
1022 # typeset -g POWERLEVEL9K_PHP_VERSION_VISUAL_IDENTIFIER_EXPANSION='⭐'
1023
1024 ##########[ laravel_version: laravel php framework version (https://laravel.com/) ]###########
1025 # Laravel version color.
1026 typeset -g POWERLEVEL9K_LARAVEL_VERSION_FOREGROUND=161
1027 # Custom icon.
1028 # typeset -g POWERLEVEL9K_LARAVEL_VERSION_VISUAL_IDENTIFIER_EXPANSION='⭐'
1029
1030 ####################[ java_version: java version (https://www.java.com/) ]####################
1031 # Java version color.
1032 typeset -g POWERLEVEL9K_JAVA_VERSION_FOREGROUND=32
1033 # Show java version only when in a java project subdirectory.
1034 typeset -g POWERLEVEL9K_JAVA_VERSION_PROJECT_ONLY=true
1035 # Show brief version.
1036 typeset -g POWERLEVEL9K_JAVA_VERSION_FULL=false
1037 # Custom icon.
1038 # typeset -g POWERLEVEL9K_JAVA_VERSION_VISUAL_IDENTIFIER_EXPANSION='⭐'
1039
1040 ###[ package: name@version from package.json (https://docs.npmjs.com/files/package.json) ]####
1041 # Package color.
1042 typeset -g POWERLEVEL9K_PACKAGE_FOREGROUND=117
1043 # Package format. The following parameters are available within the expansion.
1044 #
1045 # - P9K_PACKAGE_NAME The value of `name` field in package.json.
1046 # - P9K_PACKAGE_VERSION The value of `version` field in package.json.
1047 #
1048 # typeset -g POWERLEVEL9K_PACKAGE_CONTENT_EXPANSION='${P9K_PACKAGE_NAME//\%/%%}@${P9K_PACKAGE_VERSION//\%/%%}'
1049 # Custom icon.
1050 # typeset -g POWERLEVEL9K_PACKAGE_VISUAL_IDENTIFIER_EXPANSION='⭐'
1051
1052 #############[ rbenv: ruby version from rbenv (https://github.com/rbenv/rbenv) ]##############
1053 # Rbenv color.
1054 typeset -g POWERLEVEL9K_RBENV_FOREGROUND=168
1055 # Hide ruby version if it doesn't come from one of these sources.
1056 typeset -g POWERLEVEL9K_RBENV_SOURCES=(shell local global)
1057 # If set to false, hide ruby version if it's the same as global:
1058 # $(rbenv version-name) == $(rbenv global).
1059 typeset -g POWERLEVEL9K_RBENV_PROMPT_ALWAYS_SHOW=false
1060 # If set to false, hide ruby version if it's equal to "system".
1061 typeset -g POWERLEVEL9K_RBENV_SHOW_SYSTEM=true
1062 # Custom icon.
1063 # typeset -g POWERLEVEL9K_RBENV_VISUAL_IDENTIFIER_EXPANSION='⭐'
1064
1065 #######################[ rvm: ruby version from rvm (https://rvm.io) ]########################
1066 # Rvm color.
1067 typeset -g POWERLEVEL9K_RVM_FOREGROUND=168
1068 # Don't show @gemset at the end.
1069 typeset -g POWERLEVEL9K_RVM_SHOW_GEMSET=false
1070 # Don't show ruby- at the front.
1071 typeset -g POWERLEVEL9K_RVM_SHOW_PREFIX=false
1072 # Custom icon.
1073 # typeset -g POWERLEVEL9K_RVM_VISUAL_IDENTIFIER_EXPANSION='⭐'
1074
1075 ###########[ fvm: flutter version management (https://github.com/leoafarias/fvm) ]############
1076 # Fvm color.
1077 typeset -g POWERLEVEL9K_FVM_FOREGROUND=38
1078 # Custom icon.
1079 # typeset -g POWERLEVEL9K_FVM_VISUAL_IDENTIFIER_EXPANSION='⭐'
1080
1081 ##########[ luaenv: lua version from luaenv (https://github.com/cehoffman/luaenv) ]###########
1082 # Lua color.
1083 typeset -g POWERLEVEL9K_LUAENV_FOREGROUND=32
1084 # Hide lua version if it doesn't come from one of these sources.
1085 typeset -g POWERLEVEL9K_LUAENV_SOURCES=(shell local global)
1086 # If set to false, hide lua version if it's the same as global:
1087 # $(luaenv version-name) == $(luaenv global).
1088 typeset -g POWERLEVEL9K_LUAENV_PROMPT_ALWAYS_SHOW=false
1089 # If set to false, hide lua version if it's equal to "system".
1090 typeset -g POWERLEVEL9K_LUAENV_SHOW_SYSTEM=true
1091 # Custom icon.
1092 # typeset -g POWERLEVEL9K_LUAENV_VISUAL_IDENTIFIER_EXPANSION='⭐'
1093
1094 ###############[ jenv: java version from jenv (https://github.com/jenv/jenv) ]################
1095 # Java color.
1096 typeset -g POWERLEVEL9K_JENV_FOREGROUND=32
1097 # Hide java version if it doesn't come from one of these sources.
1098 typeset -g POWERLEVEL9K_JENV_SOURCES=(shell local global)
1099 # If set to false, hide java version if it's the same as global:
1100 # $(jenv version-name) == $(jenv global).
1101 typeset -g POWERLEVEL9K_JENV_PROMPT_ALWAYS_SHOW=false
1102 # If set to false, hide java version if it's equal to "system".
1103 typeset -g POWERLEVEL9K_JENV_SHOW_SYSTEM=true
1104 # Custom icon.
1105 # typeset -g POWERLEVEL9K_JENV_VISUAL_IDENTIFIER_EXPANSION='⭐'
1106
1107 ###########[ plenv: perl version from plenv (https://github.com/tokuhirom/plenv) ]############
1108 # Perl color.
1109 typeset -g POWERLEVEL9K_PLENV_FOREGROUND=67
1110 # Hide perl version if it doesn't come from one of these sources.
1111 typeset -g POWERLEVEL9K_PLENV_SOURCES=(shell local global)
1112 # If set to false, hide perl version if it's the same as global:
1113 # $(plenv version-name) == $(plenv global).
1114 typeset -g POWERLEVEL9K_PLENV_PROMPT_ALWAYS_SHOW=false
1115 # If set to false, hide perl version if it's equal to "system".
1116 typeset -g POWERLEVEL9K_PLENV_SHOW_SYSTEM=true
1117 # Custom icon.
1118 # typeset -g POWERLEVEL9K_PLENV_VISUAL_IDENTIFIER_EXPANSION='⭐'
1119
1120 ############[ phpenv: php version from phpenv (https://github.com/phpenv/phpenv) ]############
1121 # PHP color.
1122 typeset -g POWERLEVEL9K_PHPENV_FOREGROUND=99
1123 # Hide php version if it doesn't come from one of these sources.
1124 typeset -g POWERLEVEL9K_PHPENV_SOURCES=(shell local global)
1125 # If set to false, hide php version if it's the same as global:
1126 # $(phpenv version-name) == $(phpenv global).
1127 typeset -g POWERLEVEL9K_PHPENV_PROMPT_ALWAYS_SHOW=false
1128 # If set to false, hide php version if it's equal to "system".
1129 typeset -g POWERLEVEL9K_PHPENV_SHOW_SYSTEM=true
1130 # Custom icon.
1131 # typeset -g POWERLEVEL9K_PHPENV_VISUAL_IDENTIFIER_EXPANSION='⭐'
1132
1133 #######[ scalaenv: scala version from scalaenv (https://github.com/scalaenv/scalaenv) ]#######
1134 # Scala color.
1135 typeset -g POWERLEVEL9K_SCALAENV_FOREGROUND=160
1136 # Hide scala version if it doesn't come from one of these sources.
1137 typeset -g POWERLEVEL9K_SCALAENV_SOURCES=(shell local global)
1138 # If set to false, hide scala version if it's the same as global:
1139 # $(scalaenv version-name) == $(scalaenv global).
1140 typeset -g POWERLEVEL9K_SCALAENV_PROMPT_ALWAYS_SHOW=false
1141 # If set to false, hide scala version if it's equal to "system".
1142 typeset -g POWERLEVEL9K_SCALAENV_SHOW_SYSTEM=true
1143 # Custom icon.
1144 # typeset -g POWERLEVEL9K_SCALAENV_VISUAL_IDENTIFIER_EXPANSION='⭐'
1145
1146 ##########[ haskell_stack: haskell version from stack (https://haskellstack.org/) ]###########
1147 # Haskell color.
1148 typeset -g POWERLEVEL9K_HASKELL_STACK_FOREGROUND=172
1149 # Hide haskell version if it doesn't come from one of these sources.
1150 #
1151 # shell: version is set by STACK_YAML
1152 # local: version is set by stack.yaml up the directory tree
1153 # global: version is set by the implicit global project (~/.stack/global-project/stack.yaml)
1154 typeset -g POWERLEVEL9K_HASKELL_STACK_SOURCES=(shell local)
1155 # If set to false, hide haskell version if it's the same as in the implicit global project.
1156 typeset -g POWERLEVEL9K_HASKELL_STACK_ALWAYS_SHOW=true
1157 # Custom icon.
1158 # typeset -g POWERLEVEL9K_HASKELL_STACK_VISUAL_IDENTIFIER_EXPANSION='⭐'
1159
1160 #############[ kubecontext: current kubernetes context (https://kubernetes.io/) ]#############
1161 # Show kubecontext only when the the command you are typing invokes one of these tools.
1162 # Tip: Remove the next line to always show kubecontext.
1163 typeset -g POWERLEVEL9K_KUBECONTEXT_SHOW_ON_COMMAND='kubectl|helm|kubens|kubectx|oc|istioctl|kogito|k9s|helmfile|flux|fluxctl|stern'
1164
1165 # Kubernetes context classes for the purpose of using different colors, icons and expansions with
1166 # different contexts.
1167 #
1168 # POWERLEVEL9K_KUBECONTEXT_CLASSES is an array with even number of elements. The first element
1169 # in each pair defines a pattern against which the current kubernetes context gets matched.
1170 # More specifically, it's P9K_CONTENT prior to the application of context expansion (see below)
1171 # that gets matched. If you unset all POWERLEVEL9K_KUBECONTEXT_*CONTENT_EXPANSION parameters,
1172 # you'll see this value in your prompt. The second element of each pair in
1173 # POWERLEVEL9K_KUBECONTEXT_CLASSES defines the context class. Patterns are tried in order. The
1174 # first match wins.
1175 #
1176 # For example, given these settings:
1177 #
1178 # typeset -g POWERLEVEL9K_KUBECONTEXT_CLASSES=(
1179 # '*prod*' PROD
1180 # '*test*' TEST
1181 # '*' DEFAULT)
1182 #
1183 # If your current kubernetes context is "deathray-testing/default", its class is TEST
1184 # because "deathray-testing/default" doesn't match the pattern '*prod*' but does match '*test*'.
1185 #
1186 # You can define different colors, icons and content expansions for different classes:
1187 #
1188 # typeset -g POWERLEVEL9K_KUBECONTEXT_TEST_FOREGROUND=28
1189 # typeset -g POWERLEVEL9K_KUBECONTEXT_TEST_VISUAL_IDENTIFIER_EXPANSION='⭐'
1190 # typeset -g POWERLEVEL9K_KUBECONTEXT_TEST_CONTENT_EXPANSION='> ${P9K_CONTENT} <'
1191 typeset -g POWERLEVEL9K_KUBECONTEXT_CLASSES=(
1192 # '*prod*' PROD # These values are examples that are unlikely
1193 # '*test*' TEST # to match your needs. Customize them as needed.
1194 '*' DEFAULT)
1195 typeset -g POWERLEVEL9K_KUBECONTEXT_DEFAULT_FOREGROUND=134
1196 # typeset -g POWERLEVEL9K_KUBECONTEXT_DEFAULT_VISUAL_IDENTIFIER_EXPANSION='⭐'
1197
1198 # Use POWERLEVEL9K_KUBECONTEXT_CONTENT_EXPANSION to specify the content displayed by kubecontext
1199 # segment. Parameter expansions are very flexible and fast, too. See reference:
1200 # http://zsh.sourceforge.net/Doc/Release/Expansion.html#Parameter-Expansion.
1201 #
1202 # Within the expansion the following parameters are always available:
1203 #
1204 # - P9K_CONTENT The content that would've been displayed if there was no content
1205 # expansion defined.
1206 # - P9K_KUBECONTEXT_NAME The current context's name. Corresponds to column NAME in the
1207 # output of `kubectl config get-contexts`.
1208 # - P9K_KUBECONTEXT_CLUSTER The current context's cluster. Corresponds to column CLUSTER in the
1209 # output of `kubectl config get-contexts`.
1210 # - P9K_KUBECONTEXT_NAMESPACE The current context's namespace. Corresponds to column NAMESPACE
1211 # in the output of `kubectl config get-contexts`. If there is no
1212 # namespace, the parameter is set to "default".
1213 # - P9K_KUBECONTEXT_USER The current context's user. Corresponds to column AUTHINFO in the
1214 # output of `kubectl config get-contexts`.
1215 #
1216 # If the context points to Google Kubernetes Engine (GKE) or Elastic Kubernetes Service (EKS),
1217 # the following extra parameters are available:
1218 #
1219 # - P9K_KUBECONTEXT_CLOUD_NAME Either "gke" or "eks".
1220 # - P9K_KUBECONTEXT_CLOUD_ACCOUNT Account/project ID.
1221 # - P9K_KUBECONTEXT_CLOUD_ZONE Availability zone.
1222 # - P9K_KUBECONTEXT_CLOUD_CLUSTER Cluster.
1223 #
1224 # P9K_KUBECONTEXT_CLOUD_* parameters are derived from P9K_KUBECONTEXT_CLUSTER. For example,
1225 # if P9K_KUBECONTEXT_CLUSTER is "gke_my-account_us-east1-a_my-cluster-01":
1226 #
1227 # - P9K_KUBECONTEXT_CLOUD_NAME=gke
1228 # - P9K_KUBECONTEXT_CLOUD_ACCOUNT=my-account
1229 # - P9K_KUBECONTEXT_CLOUD_ZONE=us-east1-a
1230 # - P9K_KUBECONTEXT_CLOUD_CLUSTER=my-cluster-01
1231 #
1232 # If P9K_KUBECONTEXT_CLUSTER is "arn:aws:eks:us-east-1:123456789012:cluster/my-cluster-01":
1233 #
1234 # - P9K_KUBECONTEXT_CLOUD_NAME=eks
1235 # - P9K_KUBECONTEXT_CLOUD_ACCOUNT=123456789012
1236 # - P9K_KUBECONTEXT_CLOUD_ZONE=us-east-1
1237 # - P9K_KUBECONTEXT_CLOUD_CLUSTER=my-cluster-01
1238 typeset -g POWERLEVEL9K_KUBECONTEXT_DEFAULT_CONTENT_EXPANSION=
1239 # Show P9K_KUBECONTEXT_CLOUD_CLUSTER if it's not empty and fall back to P9K_KUBECONTEXT_NAME.
1240 POWERLEVEL9K_KUBECONTEXT_DEFAULT_CONTENT_EXPANSION+='${P9K_KUBECONTEXT_CLOUD_CLUSTER:-${P9K_KUBECONTEXT_NAME}}'
1241 # Append the current context's namespace if it's not "default".
1242 POWERLEVEL9K_KUBECONTEXT_DEFAULT_CONTENT_EXPANSION+='${${:-/$P9K_KUBECONTEXT_NAMESPACE}:#/default}'
1243
1244 # Custom prefix.
1245 # typeset -g POWERLEVEL9K_KUBECONTEXT_PREFIX='%fat '
1246
1247 ################[ terraform: terraform workspace (https://www.terraform.io) ]#################
1248 # Don't show terraform workspace if it's literally "default".
1249 typeset -g POWERLEVEL9K_TERRAFORM_SHOW_DEFAULT=false
1250 # POWERLEVEL9K_TERRAFORM_CLASSES is an array with even number of elements. The first element
1251 # in each pair defines a pattern against which the current terraform workspace gets matched.
1252 # More specifically, it's P9K_CONTENT prior to the application of context expansion (see below)
1253 # that gets matched. If you unset all POWERLEVEL9K_TERRAFORM_*CONTENT_EXPANSION parameters,
1254 # you'll see this value in your prompt. The second element of each pair in
1255 # POWERLEVEL9K_TERRAFORM_CLASSES defines the workspace class. Patterns are tried in order. The
1256 # first match wins.
1257 #
1258 # For example, given these settings:
1259 #
1260 # typeset -g POWERLEVEL9K_TERRAFORM_CLASSES=(
1261 # '*prod*' PROD
1262 # '*test*' TEST
1263 # '*' OTHER)
1264 #
1265 # If your current terraform workspace is "project_test", its class is TEST because "project_test"
1266 # doesn't match the pattern '*prod*' but does match '*test*'.
1267 #
1268 # You can define different colors, icons and content expansions for different classes:
1269 #
1270 # typeset -g POWERLEVEL9K_TERRAFORM_TEST_FOREGROUND=28
1271 # typeset -g POWERLEVEL9K_TERRAFORM_TEST_VISUAL_IDENTIFIER_EXPANSION='⭐'
1272 # typeset -g POWERLEVEL9K_TERRAFORM_TEST_CONTENT_EXPANSION='> ${P9K_CONTENT} <'
1273 typeset -g POWERLEVEL9K_TERRAFORM_CLASSES=(
1274 # '*prod*' PROD # These values are examples that are unlikely
1275 # '*test*' TEST # to match your needs. Customize them as needed.
1276 '*' OTHER)
1277 typeset -g POWERLEVEL9K_TERRAFORM_OTHER_FOREGROUND=38
1278 # typeset -g POWERLEVEL9K_TERRAFORM_OTHER_VISUAL_IDENTIFIER_EXPANSION='⭐'
1279
1280 #############[ terraform_version: terraform version (https://www.terraform.io) ]##############
1281 # Terraform version color.
1282 typeset -g POWERLEVEL9K_TERRAFORM_VERSION_FOREGROUND=38
1283 # Custom icon.
1284 # typeset -g POWERLEVEL9K_TERRAFORM_VERSION_VISUAL_IDENTIFIER_EXPANSION='⭐'
1285
1286 #[ aws: aws profile (https://docs.aws.amazon.com/cli/latest/userguide/cli-configure-profiles.html) ]#
1287 # Show aws only when the the command you are typing invokes one of these tools.
1288 # Tip: Remove the next line to always show aws.
1289 typeset -g POWERLEVEL9K_AWS_SHOW_ON_COMMAND='aws|awless|terraform|pulumi|terragrunt'
1290
1291 # POWERLEVEL9K_AWS_CLASSES is an array with even number of elements. The first element
1292 # in each pair defines a pattern against which the current AWS profile gets matched.
1293 # More specifically, it's P9K_CONTENT prior to the application of context expansion (see below)
1294 # that gets matched. If you unset all POWERLEVEL9K_AWS_*CONTENT_EXPANSION parameters,
1295 # you'll see this value in your prompt. The second element of each pair in
1296 # POWERLEVEL9K_AWS_CLASSES defines the profile class. Patterns are tried in order. The
1297 # first match wins.
1298 #
1299 # For example, given these settings:
1300 #
1301 # typeset -g POWERLEVEL9K_AWS_CLASSES=(
1302 # '*prod*' PROD
1303 # '*test*' TEST
1304 # '*' DEFAULT)
1305 #
1306 # If your current AWS profile is "company_test", its class is TEST
1307 # because "company_test" doesn't match the pattern '*prod*' but does match '*test*'.
1308 #
1309 # You can define different colors, icons and content expansions for different classes:
1310 #
1311 # typeset -g POWERLEVEL9K_AWS_TEST_FOREGROUND=28
1312 # typeset -g POWERLEVEL9K_AWS_TEST_VISUAL_IDENTIFIER_EXPANSION='⭐'
1313 # typeset -g POWERLEVEL9K_AWS_TEST_CONTENT_EXPANSION='> ${P9K_CONTENT} <'
1314 typeset -g POWERLEVEL9K_AWS_CLASSES=(
1315 # '*prod*' PROD # These values are examples that are unlikely
1316 # '*test*' TEST # to match your needs. Customize them as needed.
1317 '*' DEFAULT)
1318 typeset -g POWERLEVEL9K_AWS_DEFAULT_FOREGROUND=208
1319 # typeset -g POWERLEVEL9K_AWS_DEFAULT_VISUAL_IDENTIFIER_EXPANSION='⭐'
1320
1321 # AWS segment format. The following parameters are available within the expansion.
1322 #
1323 # - P9K_AWS_PROFILE The name of the current AWS profile.
1324 # - P9K_AWS_REGION The region associated with the current AWS profile.
1325 typeset -g POWERLEVEL9K_AWS_CONTENT_EXPANSION='${P9K_AWS_PROFILE//\%/%%}${P9K_AWS_REGION:+ ${P9K_AWS_REGION//\%/%%}}'
1326
1327 #[ aws_eb_env: aws elastic beanstalk environment (https://aws.amazon.com/elasticbeanstalk/) ]#
1328 # AWS Elastic Beanstalk environment color.
1329 typeset -g POWERLEVEL9K_AWS_EB_ENV_FOREGROUND=70
1330 # Custom icon.
1331 # typeset -g POWERLEVEL9K_AWS_EB_ENV_VISUAL_IDENTIFIER_EXPANSION='⭐'
1332
1333 ##########[ azure: azure account name (https://docs.microsoft.com/en-us/cli/azure) ]##########
1334 # Show azure only when the the command you are typing invokes one of these tools.
1335 # Tip: Remove the next line to always show azure.
1336 typeset -g POWERLEVEL9K_AZURE_SHOW_ON_COMMAND='az|terraform|pulumi|terragrunt'
1337 # Azure account name color.
1338 typeset -g POWERLEVEL9K_AZURE_FOREGROUND=32
1339 # Custom icon.
1340 # typeset -g POWERLEVEL9K_AZURE_VISUAL_IDENTIFIER_EXPANSION='⭐'
1341
1342 ##########[ gcloud: google cloud account and project (https://cloud.google.com/) ]###########
1343 # Show gcloud only when the the command you are typing invokes one of these tools.
1344 # Tip: Remove the next line to always show gcloud.
1345 typeset -g POWERLEVEL9K_GCLOUD_SHOW_ON_COMMAND='gcloud|gcs'
1346 # Google cloud color.
1347 typeset -g POWERLEVEL9K_GCLOUD_FOREGROUND=32
1348
1349 # Google cloud format. Change the value of POWERLEVEL9K_GCLOUD_PARTIAL_CONTENT_EXPANSION and/or
1350 # POWERLEVEL9K_GCLOUD_COMPLETE_CONTENT_EXPANSION if the default is too verbose or not informative
1351 # enough. You can use the following parameters in the expansions. Each of them corresponds to the
1352 # output of `gcloud` tool.
1353 #
1354 # Parameter | Source
1355 # -------------------------|--------------------------------------------------------------------
1356 # P9K_GCLOUD_CONFIGURATION | gcloud config configurations list --format='value(name)'
1357 # P9K_GCLOUD_ACCOUNT | gcloud config get-value account
1358 # P9K_GCLOUD_PROJECT_ID | gcloud config get-value project
1359 # P9K_GCLOUD_PROJECT_NAME | gcloud projects describe $P9K_GCLOUD_PROJECT_ID --format='value(name)'
1360 #
1361 # Note: ${VARIABLE//\%/%%} expands to ${VARIABLE} with all occurrences of '%' replaced with '%%'.
1362 #
1363 # Obtaining project name requires sending a request to Google servers. This can take a long time
1364 # and even fail. When project name is unknown, P9K_GCLOUD_PROJECT_NAME is not set and gcloud
1365 # prompt segment is in state PARTIAL. When project name gets known, P9K_GCLOUD_PROJECT_NAME gets
1366 # set and gcloud prompt segment transitions to state COMPLETE.
1367 #
1368 # You can customize the format, icon and colors of gcloud segment separately for states PARTIAL
1369 # and COMPLETE. You can also hide gcloud in state PARTIAL by setting
1370 # POWERLEVEL9K_GCLOUD_PARTIAL_VISUAL_IDENTIFIER_EXPANSION and
1371 # POWERLEVEL9K_GCLOUD_PARTIAL_CONTENT_EXPANSION to empty.
1372 typeset -g POWERLEVEL9K_GCLOUD_PARTIAL_CONTENT_EXPANSION='${P9K_GCLOUD_PROJECT_ID//\%/%%}'
1373 typeset -g POWERLEVEL9K_GCLOUD_COMPLETE_CONTENT_EXPANSION='${P9K_GCLOUD_PROJECT_NAME//\%/%%}'
1374
1375 # Send a request to Google (by means of `gcloud projects describe ...`) to obtain project name
1376 # this often. Negative value disables periodic polling. In this mode project name is retrieved
1377 # only when the current configuration, account or project id changes.
1378 typeset -g POWERLEVEL9K_GCLOUD_REFRESH_PROJECT_NAME_SECONDS=60
1379
1380 # Custom icon.
1381 # typeset -g POWERLEVEL9K_GCLOUD_VISUAL_IDENTIFIER_EXPANSION='⭐'
1382
1383 #[ google_app_cred: google application credentials (https://cloud.google.com/docs/authentication/production) ]#
1384 # Show google_app_cred only when the the command you are typing invokes one of these tools.
1385 # Tip: Remove the next line to always show google_app_cred.
1386 typeset -g POWERLEVEL9K_GOOGLE_APP_CRED_SHOW_ON_COMMAND='terraform|pulumi|terragrunt'
1387
1388 # Google application credentials classes for the purpose of using different colors, icons and
1389 # expansions with different credentials.
1390 #
1391 # POWERLEVEL9K_GOOGLE_APP_CRED_CLASSES is an array with even number of elements. The first
1392 # element in each pair defines a pattern against which the current kubernetes context gets
1393 # matched. More specifically, it's P9K_CONTENT prior to the application of context expansion
1394 # (see below) that gets matched. If you unset all POWERLEVEL9K_GOOGLE_APP_CRED_*CONTENT_EXPANSION
1395 # parameters, you'll see this value in your prompt. The second element of each pair in
1396 # POWERLEVEL9K_GOOGLE_APP_CRED_CLASSES defines the context class. Patterns are tried in order.
1397 # The first match wins.
1398 #
1399 # For example, given these settings:
1400 #
1401 # typeset -g POWERLEVEL9K_GOOGLE_APP_CRED_CLASSES=(
1402 # '*:*prod*:*' PROD
1403 # '*:*test*:*' TEST
1404 # '*' DEFAULT)
1405 #
1406 # If your current Google application credentials is "service_account deathray-testing x@y.com",
1407 # its class is TEST because it doesn't match the pattern '* *prod* *' but does match '* *test* *'.
1408 #
1409 # You can define different colors, icons and content expansions for different classes:
1410 #
1411 # typeset -g POWERLEVEL9K_GOOGLE_APP_CRED_TEST_FOREGROUND=28
1412 # typeset -g POWERLEVEL9K_GOOGLE_APP_CRED_TEST_VISUAL_IDENTIFIER_EXPANSION='⭐'
1413 # typeset -g POWERLEVEL9K_GOOGLE_APP_CRED_TEST_CONTENT_EXPANSION='$P9K_GOOGLE_APP_CRED_PROJECT_ID'
1414 typeset -g POWERLEVEL9K_GOOGLE_APP_CRED_CLASSES=(
1415 # '*:*prod*:*' PROD # These values are examples that are unlikely
1416 # '*:*test*:*' TEST # to match your needs. Customize them as needed.
1417 '*' DEFAULT)
1418 typeset -g POWERLEVEL9K_GOOGLE_APP_CRED_DEFAULT_FOREGROUND=32
1419 # typeset -g POWERLEVEL9K_GOOGLE_APP_CRED_DEFAULT_VISUAL_IDENTIFIER_EXPANSION='⭐'
1420
1421 # Use POWERLEVEL9K_GOOGLE_APP_CRED_CONTENT_EXPANSION to specify the content displayed by
1422 # google_app_cred segment. Parameter expansions are very flexible and fast, too. See reference:
1423 # http://zsh.sourceforge.net/Doc/Release/Expansion.html#Parameter-Expansion.
1424 #
1425 # You can use the following parameters in the expansion. Each of them corresponds to one of the
1426 # fields in the JSON file pointed to by GOOGLE_APPLICATION_CREDENTIALS.
1427 #
1428 # Parameter | JSON key file field
1429 # ---------------------------------+---------------
1430 # P9K_GOOGLE_APP_CRED_TYPE | type
1431 # P9K_GOOGLE_APP_CRED_PROJECT_ID | project_id
1432 # P9K_GOOGLE_APP_CRED_CLIENT_EMAIL | client_email
1433 #
1434 # Note: ${VARIABLE//\%/%%} expands to ${VARIABLE} with all occurrences of '%' replaced by '%%'.
1435 typeset -g POWERLEVEL9K_GOOGLE_APP_CRED_DEFAULT_CONTENT_EXPANSION='${P9K_GOOGLE_APP_CRED_PROJECT_ID//\%/%%}'
1436
1437 ##############[ toolbox: toolbox name (https://github.com/containers/toolbox) ]###############
1438 # Toolbox color.
1439 typeset -g POWERLEVEL9K_TOOLBOX_FOREGROUND=178
1440 # Don't display the name of the toolbox if it matches fedora-toolbox-*.
1441 typeset -g POWERLEVEL9K_TOOLBOX_CONTENT_EXPANSION='${P9K_TOOLBOX_NAME:#fedora-toolbox-*}'
1442 # Custom icon.
1443 # typeset -g POWERLEVEL9K_TOOLBOX_VISUAL_IDENTIFIER_EXPANSION='⭐'
1444 # Custom prefix.
1445 # typeset -g POWERLEVEL9K_TOOLBOX_PREFIX='%fin '
1446
1447 ###############################[ public_ip: public IP address ]###############################
1448 # Public IP color.
1449 typeset -g POWERLEVEL9K_PUBLIC_IP_FOREGROUND=94
1450 # Custom icon.
1451 # typeset -g POWERLEVEL9K_PUBLIC_IP_VISUAL_IDENTIFIER_EXPANSION='⭐'
1452
1453 ########################[ vpn_ip: virtual private network indicator ]#########################
1454 # VPN IP color.
1455 typeset -g POWERLEVEL9K_VPN_IP_FOREGROUND=81
1456 # When on VPN, show just an icon without the IP address.
1457 # Tip: To display the private IP address when on VPN, remove the next line.
1458 typeset -g POWERLEVEL9K_VPN_IP_CONTENT_EXPANSION=
1459 # Regular expression for the VPN network interface. Run `ifconfig` or `ip -4 a show` while on VPN
1460 # to see the name of the interface.
1461 typeset -g POWERLEVEL9K_VPN_IP_INTERFACE='(gpd|wg|(.*tun)|tailscale)[0-9]*'
1462 # If set to true, show one segment per matching network interface. If set to false, show only
1463 # one segment corresponding to the first matching network interface.
1464 # Tip: If you set it to true, you'll probably want to unset POWERLEVEL9K_VPN_IP_CONTENT_EXPANSION.
1465 typeset -g POWERLEVEL9K_VPN_IP_SHOW_ALL=false
1466 # Custom icon.
1467 # typeset -g POWERLEVEL9K_VPN_IP_VISUAL_IDENTIFIER_EXPANSION='⭐'
1468
1469 ###########[ ip: ip address and bandwidth usage for a specified network interface ]###########
1470 # IP color.
1471 typeset -g POWERLEVEL9K_IP_FOREGROUND=38
1472 # The following parameters are accessible within the expansion:
1473 #
1474 # Parameter | Meaning
1475 # ----------------------+-------------------------------------------
1476 # P9K_IP_IP | IP address
1477 # P9K_IP_INTERFACE | network interface
1478 # P9K_IP_RX_BYTES | total number of bytes received
1479 # P9K_IP_TX_BYTES | total number of bytes sent
1480 # P9K_IP_RX_BYTES_DELTA | number of bytes received since last prompt
1481 # P9K_IP_TX_BYTES_DELTA | number of bytes sent since last prompt
1482 # P9K_IP_RX_RATE | receive rate (since last prompt)
1483 # P9K_IP_TX_RATE | send rate (since last prompt)
1484 typeset -g POWERLEVEL9K_IP_CONTENT_EXPANSION='$P9K_IP_IP'
1485 # Show information for the first network interface whose name matches this regular expression.
1486 # Run `ifconfig` or `ip -4 a show` to see the names of all network interfaces.
1487 typeset -g POWERLEVEL9K_IP_INTERFACE='[ew].*'
1488 # Custom icon.
1489 # typeset -g POWERLEVEL9K_IP_VISUAL_IDENTIFIER_EXPANSION='⭐'
1490
1491 #########################[ proxy: system-wide http/https/ftp proxy ]##########################
1492 # Proxy color.
1493 typeset -g POWERLEVEL9K_PROXY_FOREGROUND=68
1494 # Custom icon.
1495 # typeset -g POWERLEVEL9K_PROXY_VISUAL_IDENTIFIER_EXPANSION='⭐'
1496
1497 ################################[ battery: internal battery ]#################################
1498 # Show battery in red when it's below this level and not connected to power supply.
1499 typeset -g POWERLEVEL9K_BATTERY_LOW_THRESHOLD=20
1500 typeset -g POWERLEVEL9K_BATTERY_LOW_FOREGROUND=160
1501 # Show battery in green when it's charging or fully charged.
1502 typeset -g POWERLEVEL9K_BATTERY_{CHARGING,CHARGED}_FOREGROUND=70
1503 # Show battery in yellow when it's discharging.
1504 typeset -g POWERLEVEL9K_BATTERY_DISCONNECTED_FOREGROUND=178
1505 # Battery pictograms going from low to high level of charge.
1506 typeset -g POWERLEVEL9K_BATTERY_STAGES='\uf58d\uf579\uf57a\uf57b\uf57c\uf57d\uf57e\uf57f\uf580\uf581\uf578'
1507 # Don't show the remaining time to charge/discharge.
1508 typeset -g POWERLEVEL9K_BATTERY_VERBOSE=false
1509
1510 #####################################[ wifi: wifi speed ]#####################################
1511 # WiFi color.
1512 typeset -g POWERLEVEL9K_WIFI_FOREGROUND=68
1513 # Custom icon.
1514 # typeset -g POWERLEVEL9K_WIFI_VISUAL_IDENTIFIER_EXPANSION='⭐'
1515
1516 # Use different colors and icons depending on signal strength ($P9K_WIFI_BARS).
1517 #
1518 # # Wifi colors and icons for different signal strength levels (low to high).
1519 # typeset -g my_wifi_fg=(68 68 68 68 68) # <-- change these values
1520 # typeset -g my_wifi_icon=('WiFi' 'WiFi' 'WiFi' 'WiFi' 'WiFi') # <-- change these values
1521 #
1522 # typeset -g POWERLEVEL9K_WIFI_CONTENT_EXPANSION='%F{${my_wifi_fg[P9K_WIFI_BARS+1]}}$P9K_WIFI_LAST_TX_RATE Mbps'
1523 # typeset -g POWERLEVEL9K_WIFI_VISUAL_IDENTIFIER_EXPANSION='%F{${my_wifi_fg[P9K_WIFI_BARS+1]}}${my_wifi_icon[P9K_WIFI_BARS+1]}'
1524 #
1525 # The following parameters are accessible within the expansions:
1526 #
1527 # Parameter | Meaning
1528 # ----------------------+---------------
1529 # P9K_WIFI_SSID | service set identifier, a.k.a. network name
1530 # P9K_WIFI_LINK_AUTH | authentication protocol such as "wpa2-psk" or "none"; empty if unknown
1531 # P9K_WIFI_LAST_TX_RATE | wireless transmit rate in megabits per second
1532 # P9K_WIFI_RSSI | signal strength in dBm, from -120 to 0
1533 # P9K_WIFI_NOISE | noise in dBm, from -120 to 0
1534 # P9K_WIFI_BARS | signal strength in bars, from 0 to 4 (derived from P9K_WIFI_RSSI and P9K_WIFI_NOISE)
1535
1536 ####################################[ time: current time ]####################################
1537 # Current time color.
1538 typeset -g POWERLEVEL9K_TIME_FOREGROUND=66
1539 # Format for the current time: 09:51:02. See `man 3 strftime`.
1540 typeset -g POWERLEVEL9K_TIME_FORMAT='%D{%H:%M:%S}'
1541 # If set to true, time will update when you hit enter. This way prompts for the past
1542 # commands will contain the start times of their commands as opposed to the default
1543 # behavior where they contain the end times of their preceding commands.
1544 typeset -g POWERLEVEL9K_TIME_UPDATE_ON_COMMAND=false
1545 # Custom icon.
1546 typeset -g POWERLEVEL9K_TIME_VISUAL_IDENTIFIER_EXPANSION=
1547 # Custom prefix.
1548 # typeset -g POWERLEVEL9K_TIME_PREFIX='%fat '
1549
1550 # Example of a user-defined prompt segment. Function prompt_example will be called on every
1551 # prompt if `example` prompt segment is added to POWERLEVEL9K_LEFT_PROMPT_ELEMENTS or
1552 # POWERLEVEL9K_RIGHT_PROMPT_ELEMENTS. It displays an icon and orange text greeting the user.
1553 #
1554 # Type `p10k help segment` for documentation and a more sophisticated example.
1555 function prompt_example() {
1556 p10k segment -f 208 -i '⭐' -t 'hello, %n'
1557 }
1558
1559 # User-defined prompt segments may optionally provide an instant_prompt_* function. Its job
1560 # is to generate the prompt segment for display in instant prompt. See
1561 # https://github.com/romkatv/powerlevel10k/blob/master/README.md#instant-prompt.
1562 #
1563 # Powerlevel10k will call instant_prompt_* at the same time as the regular prompt_* function
1564 # and will record all `p10k segment` calls it makes. When displaying instant prompt, Powerlevel10k
1565 # will replay these calls without actually calling instant_prompt_*. It is imperative that
1566 # instant_prompt_* always makes the same `p10k segment` calls regardless of environment. If this
1567 # rule is not observed, the content of instant prompt will be incorrect.
1568 #
1569 # Usually, you should either not define instant_prompt_* or simply call prompt_* from it. If
1570 # instant_prompt_* is not defined for a segment, the segment won't be shown in instant prompt.
1571 function instant_prompt_example() {
1572 # Since prompt_example always makes the same `p10k segment` calls, we can call it from
1573 # instant_prompt_example. This will give us the same `example` prompt segment in the instant
1574 # and regular prompts.
1575 prompt_example
1576 }
1577
1578 # User-defined prompt segments can be customized the same way as built-in segments.
1579 # typeset -g POWERLEVEL9K_EXAMPLE_FOREGROUND=208
1580 # typeset -g POWERLEVEL9K_EXAMPLE_VISUAL_IDENTIFIER_EXPANSION='⭐'
1581
1582 # Transient prompt works similarly to the builtin transient_rprompt option. It trims down prompt
1583 # when accepting a command line. Supported values:
1584 #
1585 # - off: Don't change prompt when accepting a command line.
1586 # - always: Trim down prompt when accepting a command line.
1587 # - same-dir: Trim down prompt when accepting a command line unless this is the first command
1588 # typed after changing current working directory.
1589 typeset -g POWERLEVEL9K_TRANSIENT_PROMPT=always
1590
1591 # Instant prompt mode.
1592 #
1593 # - off: Disable instant prompt. Choose this if you've tried instant prompt and found
1594 # it incompatible with your zsh configuration files.
1595 # - quiet: Enable instant prompt and don't print warnings when detecting console output
1596 # during zsh initialization. Choose this if you've read and understood
1597 # https://github.com/romkatv/powerlevel10k/blob/master/README.md#instant-prompt.
1598 # - verbose: Enable instant prompt and print a warning when detecting console output during
1599 # zsh initialization. Choose this if you've never tried instant prompt, haven't
1600 # seen the warning, or if you are unsure what this all means.
1601 typeset -g POWERLEVEL9K_INSTANT_PROMPT=verbose
1602
1603 # Hot reload allows you to change POWERLEVEL9K options after Powerlevel10k has been initialized.
1604 # For example, you can type POWERLEVEL9K_BACKGROUND=red and see your prompt turn red. Hot reload
1605 # can slow down prompt by 1-2 milliseconds, so it's better to keep it turned off unless you
1606 # really need it.
1607 typeset -g POWERLEVEL9K_DISABLE_HOT_RELOAD=true
1608
1609 # If p10k is already loaded, reload configuration.
1610 # This works even with POWERLEVEL9K_DISABLE_HOT_RELOAD=true.
1611 (( ! $+functions[p10k] )) || p10k reload
1612}
1613
1614# Tell `p10k configure` which file it should overwrite.
1615typeset -g POWERLEVEL9K_CONFIG_FILE=${${(%):-%x}:a}
1616
1617(( ${#p10k_config_opts} )) && setopt ${p10k_config_opts[@]}
1618'builtin' 'unset' 'p10k_config_opts'