From 4e81640ec490c4d3fb7062ca4d3a2c4f5b72784b Mon Sep 17 00:00:00 2001 From: root Date: Mon, 30 May 2016 21:07:32 +0000 Subject: [PATCH 1/3] root gets red dir on blecher.at-agnoster theme --- themes/blecher.at-agnoster.zsh-theme | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/themes/blecher.at-agnoster.zsh-theme b/themes/blecher.at-agnoster.zsh-theme index e7290734a..833884ab6 100644 --- a/themes/blecher.at-agnoster.zsh-theme +++ b/themes/blecher.at-agnoster.zsh-theme @@ -28,6 +28,7 @@ CURRENT_BG='NONE' SEGMENT_SEPARATOR='' +DIR_COLOR='blue' # Begin a segment # Takes two arguments, background and foreground. Both can be omitted, @@ -62,7 +63,10 @@ prompt_end() { # Context: user@hostname (who am I and where am I) prompt_context() { local user=`whoami` - + if [[ "$user" == "root" ]]; then + DIR_COLOR=red + fi + if [[ "$user" != "$DEFAULT_USER" || -n "$SSH_CLIENT" ]]; then prompt_segment black default "%(!.%{%F{yellow}%}.)$user@%m" fi @@ -83,7 +87,7 @@ prompt_git() { # Dir: current working directory prompt_dir() { - prompt_segment blue black '%~' + prompt_segment $DIR_COLOR black '%~' } # Fast method to get the current branch in git from https://gist.github.com/wolever/6525437 From b46b1216264c2989cff004efe00390d5cfdac639 Mon Sep 17 00:00:00 2001 From: root Date: Mon, 30 May 2016 21:11:32 +0000 Subject: [PATCH 2/3] default zsh profile: disable autoupdate --- templates/zshrc.zsh-template | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/templates/zshrc.zsh-template b/templates/zshrc.zsh-template index 0058c643b..180c76ace 100644 --- a/templates/zshrc.zsh-template +++ b/templates/zshrc.zsh-template @@ -11,7 +11,7 @@ ZSH_THEME="blecher.at-agnoster" # CASE_SENSITIVE="true" # Uncomment the following line to disable bi-weekly auto-update checks. -# DISABLE_AUTO_UPDATE="true" +DISABLE_AUTO_UPDATE="true" # Uncomment the following line to change how often to auto-update (in days). # export UPDATE_ZSH_DAYS=13 From ceab564d11b149b69f89b88fc114d5a508a43e44 Mon Sep 17 00:00:00 2001 From: root Date: Mon, 30 May 2016 23:31:37 +0200 Subject: [PATCH 3/3] fix grep_opts --- lib/grep.zsh | 1 - oh-my-zsh.sh | 0 2 files changed, 1 deletion(-) mode change 100644 => 100755 oh-my-zsh.sh diff --git a/lib/grep.zsh b/lib/grep.zsh index 276fec382..27af6e36e 100644 --- a/lib/grep.zsh +++ b/lib/grep.zsh @@ -20,5 +20,4 @@ elif grep-flag-available --exclude=.cvs; then fi unfunction grep-flag-available -export GREP_OPTIONS="$GREP_OPTIONS" export GREP_COLOR='1;32' diff --git a/oh-my-zsh.sh b/oh-my-zsh.sh old mode 100644 new mode 100755