From 8b63c5b5f37ada9f54b7f46d4e6fafad27133f1f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marcin=20R=C3=B3=C5=BCewski?= Date: Fri, 6 Sep 2024 02:38:02 +0200 Subject: [PATCH] fix: Customize right prompt when Neovim is opened This is for terminal right prompt when Neovim is opened based on the environment variable. If the `MYVIMRC` env is set, then the code for adjusting rignt prompt indent is change. Also fixed some typos. --- config/zsh/.zshrc | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/config/zsh/.zshrc b/config/zsh/.zshrc index 4363b43..f6a773a 100644 --- a/config/zsh/.zshrc +++ b/config/zsh/.zshrc @@ -40,8 +40,8 @@ ZSH_THEME="powerlevel10k/powerlevel10k" CASE_SENSITIVE="true" # Remind me to update when it's time and how often in days -zstyle ':omz:update' mode reminder -zstyle ':omz:update' frequency 7 +zstyle ":omz:update" mode reminder +zstyle ":omz:update" frequency 7 # Enable command auto-correction ENABLE_CORRECTION="true" @@ -52,6 +52,11 @@ COMPLETION_WAITING_DOTS="true" # Adjustment to the right side ZLE_RPROMPT_INDENT=0 +# When Neovim is opened, customize the right prompt +if [[ -n $MYVIMRC ]]; then + ZLE_RPROMPT_INDENT=2 +fi + # Execution time stamp shown in the history command output HIST_STAMPS="yyyy-mm-dd"