From cc4878aef2bdefbac98fa135fca6070d27e4f041 Mon Sep 17 00:00:00 2001 From: Roman Perepelitsa Date: Sun, 11 Jun 2023 09:07:41 +0200 Subject: fix chezmoi segment and rename it to chezmoi_shell (#2311) - Link to the project's homepage rather than its source code. - Move `chezmoi_shell` next to all the other *shell indicator* segments. - Use a shade of blue that resembes the color on chezmoi.io. - Don't go beyond 8 colors in 8-color configs. - Remove the segment from the *pure* config. - Fix whitespace padding on `CHEZMOI_ICON`. - Use the appropriate icon with all fonts (the same as `HOME`). - Add missing `CHEZMOI_ICON` definitions for "powerline" and "ascii" font modes. - Remove the redundant literal "chezmoi" content from the segment. - Fix instant prompt so that the segment is shown only when `$CHEZMOI` is non-empty. --- config/p10k-classic.zsh | 14 +++++++------- config/p10k-lean-8colors.zsh | 14 +++++++------- config/p10k-lean.zsh | 14 +++++++------- config/p10k-pure.zsh | 1 - config/p10k-rainbow.zsh | 16 ++++++++-------- 5 files changed, 29 insertions(+), 30 deletions(-) (limited to 'config') diff --git a/config/p10k-classic.zsh b/config/p10k-classic.zsh index 8a52ae1e..5ea3dba3 100644 --- a/config/p10k-classic.zsh +++ b/config/p10k-classic.zsh @@ -42,7 +42,6 @@ status # exit code of the last command command_execution_time # duration of the last command background_jobs # presence of background jobs - chezmoi # chezmoi prompt (https://github.com/twpayne/chezmoi) direnv # direnv status (https://direnv.net/) asdf # asdf version manager (https://github.com/asdf-vm/asdf) virtualenv # python virtual environment (https://docs.python.org/3/library/venv.html) @@ -88,6 +87,7 @@ vim_shell # vim shell indicator (:sh) midnight_commander # midnight commander shell (https://midnight-commander.org/) nix_shell # nix shell (https://nixos.org/nixos/nix-pills/developing-with-nix-shell.html) + chezmoi_shell # chezmoi shell (https://www.chezmoi.io/) # vi_mode # vi mode (you don't need this if you've enabled prompt_char) # vpn_ip # virtual private network indicator # load # CPU load @@ -740,12 +740,6 @@ # Custom icon. # typeset -g POWERLEVEL9K_XPLR_VISUAL_IDENTIFIER_EXPANSION='⭐' - ##################[ chezmoi: chezmoi shell (https://github.com/twpayne/chezmoi) ]################## - # chezmoi shell color. - typeset -g POWERLEVEL9K_CHEZMOI_FOREGROUND=72 - # Custom icon. - # typeset -g POWERLEVEL9K_CHEZMOI_VISUAL_IDENTIFIER_EXPANSION='⭐' - ###########################[ vim_shell: vim shell indicator (:sh) ]########################### # Vim shell indicator color. typeset -g POWERLEVEL9K_VIM_SHELL_FOREGROUND=34 @@ -771,6 +765,12 @@ # Custom icon. # typeset -g POWERLEVEL9K_NIX_SHELL_VISUAL_IDENTIFIER_EXPANSION='⭐' + ##################[ chezmoi_shell: chezmoi shell (https://www.chezmoi.io/) ]################## + # chezmoi shell color. + typeset -g POWERLEVEL9K_CHEZMOI_SHELL_FOREGROUND=33 + # Custom icon. + # typeset -g POWERLEVEL9K_CHEZMOI_SHELL_VISUAL_IDENTIFIER_EXPANSION='⭐' + ##################################[ disk_usage: disk usage ]################################## # Colors for different levels of disk usage. typeset -g POWERLEVEL9K_DISK_USAGE_NORMAL_FOREGROUND=35 diff --git a/config/p10k-lean-8colors.zsh b/config/p10k-lean-8colors.zsh index b4ee4e8a..3ce3f2c9 100644 --- a/config/p10k-lean-8colors.zsh +++ b/config/p10k-lean-8colors.zsh @@ -42,7 +42,6 @@ status # exit code of the last command command_execution_time # duration of the last command background_jobs # presence of background jobs - chezmoi # chezmoi prompt (https://github.com/twpayne/chezmoi) direnv # direnv status (https://direnv.net/) asdf # asdf version manager (https://github.com/asdf-vm/asdf) virtualenv # python virtual environment (https://docs.python.org/3/library/venv.html) @@ -88,6 +87,7 @@ vim_shell # vim shell indicator (:sh) midnight_commander # midnight commander shell (https://midnight-commander.org/) nix_shell # nix shell (https://nixos.org/nixos/nix-pills/developing-with-nix-shell.html) + chezmoi_shell # chezmoi shell (https://www.chezmoi.io/) # vpn_ip # virtual private network indicator # load # CPU load # disk_usage # disk usage @@ -735,12 +735,6 @@ # Custom icon. # typeset -g POWERLEVEL9K_XPLR_VISUAL_IDENTIFIER_EXPANSION='⭐' - ##################[ chezmoi: chezmoi shell (https://github.com/twpayne/chezmoi) ]################## - # chezmoi shell color. - typeset -g POWERLEVEL9K_CHEZMOI_FOREGROUND=72 - # Custom icon. - # typeset -g POWERLEVEL9K_CHEZMOI_VISUAL_IDENTIFIER_EXPANSION='⭐' - ###########################[ vim_shell: vim shell indicator (:sh) ]########################### # Vim shell indicator color. typeset -g POWERLEVEL9K_VIM_SHELL_FOREGROUND=3 @@ -766,6 +760,12 @@ # Custom icon. # typeset -g POWERLEVEL9K_NIX_SHELL_VISUAL_IDENTIFIER_EXPANSION='⭐' + ##################[ chezmoi_shell: chezmoi shell (https://www.chezmoi.io/) ]################## + # chezmoi shell color. + typeset -g POWERLEVEL9K_CHEZMOI_SHELL_FOREGROUND=4 + # Custom icon. + # typeset -g POWERLEVEL9K_CHEZMOI_SHELL_VISUAL_IDENTIFIER_EXPANSION='⭐' + ##################################[ disk_usage: disk usage ]################################## # Colors for different levels of disk usage. typeset -g POWERLEVEL9K_DISK_USAGE_NORMAL_FOREGROUND=2 diff --git a/config/p10k-lean.zsh b/config/p10k-lean.zsh index 1c8520bd..e08237bf 100644 --- a/config/p10k-lean.zsh +++ b/config/p10k-lean.zsh @@ -42,7 +42,6 @@ status # exit code of the last command command_execution_time # duration of the last command background_jobs # presence of background jobs - chezmoi # chezmoi prompt (https://github.com/twpayne/chezmoi) direnv # direnv status (https://direnv.net/) asdf # asdf version manager (https://github.com/asdf-vm/asdf) virtualenv # python virtual environment (https://docs.python.org/3/library/venv.html) @@ -88,6 +87,7 @@ vim_shell # vim shell indicator (:sh) midnight_commander # midnight commander shell (https://midnight-commander.org/) nix_shell # nix shell (https://nixos.org/nixos/nix-pills/developing-with-nix-shell.html) + chezmoi_shell # chezmoi shell (https://www.chezmoi.io/) # vpn_ip # virtual private network indicator # load # CPU load # disk_usage # disk usage @@ -731,12 +731,6 @@ # Custom icon. # typeset -g POWERLEVEL9K_XPLR_VISUAL_IDENTIFIER_EXPANSION='⭐' - ##################[ chezmoi: chezmoi shell (https://github.com/twpayne/chezmoi) ]################## - # chezmoi shell color. - typeset -g POWERLEVEL9K_CHEZMOI_FOREGROUND=72 - # Custom icon. - # typeset -g POWERLEVEL9K_CHEZMOI_VISUAL_IDENTIFIER_EXPANSION='⭐' - ###########################[ vim_shell: vim shell indicator (:sh) ]########################### # Vim shell indicator color. typeset -g POWERLEVEL9K_VIM_SHELL_FOREGROUND=34 @@ -762,6 +756,12 @@ # Custom icon. # typeset -g POWERLEVEL9K_NIX_SHELL_VISUAL_IDENTIFIER_EXPANSION='⭐' + ##################[ chezmoi_shell: chezmoi shell (https://www.chezmoi.io/) ]################## + # chezmoi shell color. + typeset -g POWERLEVEL9K_CHEZMOI_SHELL_FOREGROUND=33 + # Custom icon. + # typeset -g POWERLEVEL9K_CHEZMOI_SHELL_VISUAL_IDENTIFIER_EXPANSION='⭐' + ##################################[ disk_usage: disk usage ]################################## # Colors for different levels of disk usage. typeset -g POWERLEVEL9K_DISK_USAGE_NORMAL_FOREGROUND=35 diff --git a/config/p10k-pure.zsh b/config/p10k-pure.zsh index 4682fc76..97c1a207 100644 --- a/config/p10k-pure.zsh +++ b/config/p10k-pure.zsh @@ -51,7 +51,6 @@ newline # \n virtualenv # python virtual environment prompt_char # prompt symbol - chezmoi # chezmoi prompt (https://github.com/twpayne/chezmoi) ) # Right prompt segments. diff --git a/config/p10k-rainbow.zsh b/config/p10k-rainbow.zsh index f8290dc2..48fdacfd 100644 --- a/config/p10k-rainbow.zsh +++ b/config/p10k-rainbow.zsh @@ -45,7 +45,6 @@ direnv # direnv status (https://direnv.net/) asdf # asdf version manager (https://github.com/asdf-vm/asdf) virtualenv # python virtual environment (https://docs.python.org/3/library/venv.html) - chezmoi # chezmoi prompt (https://github.com/twpayne/chezmoi) anaconda # conda environment (https://conda.io/) pyenv # python environment (https://github.com/pyenv/pyenv) goenv # go environment (https://github.com/syndbg/goenv) @@ -88,6 +87,7 @@ vim_shell # vim shell indicator (:sh) midnight_commander # midnight commander shell (https://midnight-commander.org/) nix_shell # nix shell (https://nixos.org/nixos/nix-pills/developing-with-nix-shell.html) + chezmoi_shell # chezmoi shell (https://www.chezmoi.io/) # vi_mode # vi mode (you don't need this if you've enabled prompt_char) # vpn_ip # virtual private network indicator # load # CPU load @@ -762,13 +762,6 @@ # Custom icon. # typeset -g POWERLEVEL9K_XPLR_VISUAL_IDENTIFIER_EXPANSION='⭐' - ##################[ chezmoi: chezmoi shell (https://github.com/twpayne/chezmoi) ]################## - # chezmoi shell color. - typeset -g POWERLEVEL9K_CHEZMOI_FOREGROUND=0 - typeset -g POWERLEVEL9K_CHEZMOI_BACKGROUND=6 - # Custom icon. - # typeset -g POWERLEVEL9K_CHEZMOI_VISUAL_IDENTIFIER_EXPANSION='⭐' - ###########################[ vim_shell: vim shell indicator (:sh) ]########################### # Vim shell indicator color. typeset -g POWERLEVEL9K_VIM_SHELL_FOREGROUND=0 @@ -797,6 +790,13 @@ # Custom icon. # typeset -g POWERLEVEL9K_NIX_SHELL_VISUAL_IDENTIFIER_EXPANSION='⭐' + ##################[ chezmoi_shell: chezmoi shell (https://www.chezmoi.io/) ]################## + # chezmoi shell color. + typeset -g POWERLEVEL9K_CHEZMOI_SHELL_FOREGROUND=0 + typeset -g POWERLEVEL9K_CHEZMOI_SHELL_BACKGROUND=4 + # Custom icon. + # typeset -g POWERLEVEL9K_CHEZMOI_SHELL_VISUAL_IDENTIFIER_EXPANSION='⭐' + ##################################[ disk_usage: disk usage ]################################## # Colors for different levels of disk usage. typeset -g POWERLEVEL9K_DISK_USAGE_NORMAL_FOREGROUND=3 -- cgit v1.2.3