From 26a4094d84387e692a67bb9dd530f83eb1c4c601 Mon Sep 17 00:00:00 2001 From: Florian Rey Date: Wed, 23 Oct 2024 11:09:15 +0200 Subject: [PATCH] [Lazy] Switch to zsh / oh-my-zsh (kube-ps1) --- lazy.kubernetes/.manala/etc/zsh/.zshrc.tmpl | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) diff --git a/lazy.kubernetes/.manala/etc/zsh/.zshrc.tmpl b/lazy.kubernetes/.manala/etc/zsh/.zshrc.tmpl index a5ad0f13..59c8b5b7 100644 --- a/lazy.kubernetes/.manala/etc/zsh/.zshrc.tmpl +++ b/lazy.kubernetes/.manala/etc/zsh/.zshrc.tmpl @@ -77,6 +77,7 @@ plugins=( zsh-syntax-highlighting fzf kubectl + kube-ps1 {{- if .Vars.system.docker }} docker {{- end }} @@ -146,6 +147,16 @@ source $ZSH/oh-my-zsh.sh # alias zshconfig="mate ~/.zshrc" # alias ohmyzsh="mate ~/.oh-my-zsh" +## Kube-ps1 configuration + +KUBE_PS1_SEPARATOR='' +KUBE_PS1_CTX_COLOR=blue +KUBE_PS1_SYMBOL_COLOR=blue +KUBE_PS1_PREFIX=[ +KUBE_PS1_PREFIX_COLOR=blue +KUBE_PS1_SUFFIX=] +KUBE_PS1_SUFFIX_COLOR=blue + # Theme customization -PROMPT="%{$fg[green]%}╭─%n@%m %{$reset_color%}%{$fg[yellow]%}in %1~ %{$reset_color%}${git_branch} -%{$fg[green]%}╰\$ %{$reset_color%}" +PROMPT='%{$fg[green]%}╭─%n@%m %{$reset_color%}%{$fg[yellow]%}in %1~ %{$reset_color%}%{$FG[008]%}•%{$reset_color%} $(kube_ps1) +%{$fg[green]%}╰\$ %{$reset_color%}'