From 4e9a61dcdd1dc0ebb63f236dd3083fff92057ee0 Mon Sep 17 00:00:00 2001 From: Carlos Cardoso Date: Sat, 12 Apr 2014 18:00:12 -0300 Subject: [PATCH 1/9] added custom python support from brew --- templates/zshrc-mac.zsh | 2 ++ 1 file changed, 2 insertions(+) diff --git a/templates/zshrc-mac.zsh b/templates/zshrc-mac.zsh index 2a1895e60..d3ce618a7 100644 --- a/templates/zshrc-mac.zsh +++ b/templates/zshrc-mac.zsh @@ -38,6 +38,8 @@ plugins=(git gitfast postgres tmux python vim-override virtualenvwrapper) # User configuration if [ -e $HOME/bin ]; then export PATH="$HOME/bin:$PATH"; fi if [ -e /usr/local/bin ]; then export PATH="/usr/local/bin:$PATH"; fi +if [ -e /usr/local/share/python ]; then export PATH="/usr/local/share/python:$PATH"; fi +if [ -e /usr/local/share/python3 ]; then export PATH="/usr/local/share/python3:$PATH"; fi export EDITOR='vim' # Language configuration From e2bede24caba55541a43f28d30021c7db6209387 Mon Sep 17 00:00:00 2001 From: Carlos Cardoso Date: Sat, 19 Apr 2014 11:12:30 -0300 Subject: [PATCH 2/9] updated python initialization for macosx --- templates/zshrc-mac.zsh | 6 ------ 1 file changed, 6 deletions(-) diff --git a/templates/zshrc-mac.zsh b/templates/zshrc-mac.zsh index d3ce618a7..fbce8bf88 100644 --- a/templates/zshrc-mac.zsh +++ b/templates/zshrc-mac.zsh @@ -37,18 +37,12 @@ plugins=(git gitfast postgres tmux python vim-override virtualenvwrapper) # User configuration if [ -e $HOME/bin ]; then export PATH="$HOME/bin:$PATH"; fi -if [ -e /usr/local/bin ]; then export PATH="/usr/local/bin:$PATH"; fi -if [ -e /usr/local/share/python ]; then export PATH="/usr/local/share/python:$PATH"; fi -if [ -e /usr/local/share/python3 ]; then export PATH="/usr/local/share/python3:$PATH"; fi export EDITOR='vim' # Language configuration if [ -z "$LC_ALL" ]; then export LC_ALL=en_US.UTF-8; fi if [ -z "$LANG" ]; then export LANG=en_US.UTF-8; fi -# Compilation flags -# export ARCHFLAGS="-arch x86_64" - # MacOSX specific aliases alias bu='brew update && brew upgrade' From d4db25b6345105e4bd2388ac7f0bee22e59ad1be Mon Sep 17 00:00:00 2001 From: Carlos Cardoso Date: Sat, 19 Apr 2014 11:38:07 -0300 Subject: [PATCH 3/9] adding /usr/local/bin removed by mistake --- templates/zshrc-mac.zsh | 1 + 1 file changed, 1 insertion(+) diff --git a/templates/zshrc-mac.zsh b/templates/zshrc-mac.zsh index fbce8bf88..6fabcd183 100644 --- a/templates/zshrc-mac.zsh +++ b/templates/zshrc-mac.zsh @@ -37,6 +37,7 @@ plugins=(git gitfast postgres tmux python vim-override virtualenvwrapper) # User configuration if [ -e $HOME/bin ]; then export PATH="$HOME/bin:$PATH"; fi +if [ -e /usr/local/bin ]; then export PATH="/usr/local/bin:$PATH"; fi export EDITOR='vim' # Language configuration From 793cbb9450be5f0eabbad3347d118006b0de5551 Mon Sep 17 00:00:00 2001 From: Carlos Cardoso Date: Sat, 19 Apr 2014 11:47:19 -0300 Subject: [PATCH 4/9] removed duplicate aliases --- lib/aliases.zsh | 4 ---- 1 file changed, 4 deletions(-) diff --git a/lib/aliases.zsh b/lib/aliases.zsh index a20c6ed93..741ba1ffc 100644 --- a/lib/aliases.zsh +++ b/lib/aliases.zsh @@ -40,7 +40,3 @@ alias gits='git st' alias gitl='git l' alias gitw='git who' alias gitt='git tags' -# Aliases -alias ta='tmux attach -t' -alias tl='tmux list-session' -alias ts='tmux new-session' From 53838bb9d1ee203317492afbafe936553434a556 Mon Sep 17 00:00:00 2001 From: Carlos Cardoso Date: Sat, 26 Apr 2014 23:29:34 -0300 Subject: [PATCH 5/9] theme customization based on avit and sporty_256 --- lib/aliases.zsh | 7 ------- templates/zshrc-linux.zsh | 3 ++- templates/zshrc-mac.zsh | 2 +- themes/cadusk.zsh-theme | 40 +++++++++++++++++++++++++++++++++++++++ 4 files changed, 43 insertions(+), 9 deletions(-) create mode 100644 themes/cadusk.zsh-theme diff --git a/lib/aliases.zsh b/lib/aliases.zsh index 741ba1ffc..5e7d65bbb 100644 --- a/lib/aliases.zsh +++ b/lib/aliases.zsh @@ -33,10 +33,3 @@ alias l='ls -lah' alias ll='ls -lh' alias la='ls -lAh' alias sl=ls # often screw this up - -# Git aliases -alias gita='git add -A' -alias gits='git st' -alias gitl='git l' -alias gitw='git who' -alias gitt='git tags' diff --git a/templates/zshrc-linux.zsh b/templates/zshrc-linux.zsh index 97ec10e11..2d63750da 100644 --- a/templates/zshrc-linux.zsh +++ b/templates/zshrc-linux.zsh @@ -6,7 +6,7 @@ ZSH=$HOME/.oh-my-zsh # Optionally, if you set this to "random", it'll load a random theme each # time that oh-my-zsh is loaded. # ZSH_THEME="afowler" -ZSH_THEME="mh" +ZSH_THEME="cadusk" # Example aliases # alias zshconfig="mate ~/.zshrc" @@ -40,6 +40,7 @@ if [ -z "$LC_ALL" ]; then export LC_ALL=en_US.UTF-8; fi if [ -z "$LANG" ]; then export LANG=en_US.UTF-8; fi if [ -e $HOME/bin ]; then export PATH="$HOME/bin:$PATH"; fi +if [ -e $HOME/.local/bin ]; then export PATH="$HOME/.local/bin:$PATH"; fi if [ -e $HOME/appengine ]; then export PATH="$HOME/appengine:$PATH"; fi if [ -e $HOME/.cabal/bin ]; then export PATH="$HOME/.cabal/bin:$PATH"; fi diff --git a/templates/zshrc-mac.zsh b/templates/zshrc-mac.zsh index 6fabcd183..70bdd4312 100644 --- a/templates/zshrc-mac.zsh +++ b/templates/zshrc-mac.zsh @@ -6,7 +6,7 @@ ZSH=$HOME/.oh-my-zsh # Optionally, if you set this to "random", it'll load a random theme each # time that oh-my-zsh is loaded. # ZSH_THEME="afowler" -ZSH_THEME="mh" +ZSH_THEME="cadusk" # Example aliases # alias zshconfig="mate ~/.zshrc" diff --git a/themes/cadusk.zsh-theme b/themes/cadusk.zsh-theme new file mode 100644 index 000000000..5a39721c5 --- /dev/null +++ b/themes/cadusk.zsh-theme @@ -0,0 +1,40 @@ +# cadusk ZSH Theme - customized on top of avit theme + +PROMPT=' +$(_user_host) ${_current_dir} $(git_prompt_info) +$ ' +PROMPT2='%{$fg[white]%}$%{$reset_color%} ' + +RPROMPT='%{$(echotc UP 1)%} $(git_prompt_status) ${_return_status}%{$(echotc DO 1)%}' + +local _current_dir="%F{208}%3~%{$reset_color%} " +local _return_status="%{$fg[red]%}%(?..⍉)%{$reset_color%}" +local _hist_no="%{$fg[grey]%}%h%{$reset_color%}" + +function _user_host() { + me="%{$fg_bold[white]%}%n" + + if [[ -n $SSH_CONNECTION ]]; then + me="$me%{$fg_bold[cyan]%}@%m" + fi + echo "$me%b%{$reset_color%}" +} + +if [[ $USER == "root" ]]; then + CARETCOLOR="red" +else + CARETCOLOR="white" +fi + +MODE_INDICATOR="%{$fg_bold[yellow]%}❮%{$reset_color%}%{$fg[yellow]%}❮❮%{$reset_color%}" + +ZSH_THEME_GIT_PROMPT_PREFIX="%{$reset_color%}(%{$fg_bold[yellow]%}" +ZSH_THEME_GIT_PROMPT_SUFFIX="%{$reset_color%})" +ZSH_THEME_GIT_PROMPT_DIRTY="%{$fg[red]%}!%{$reset_color%}" +ZSH_THEME_GIT_PROMPT_CLEAN="" + +# LS colors, made with http://geoff.greer.fm/lscolors/ +export LSCOLORS="exfxcxdxbxegedabagacad" +export LS_COLORS='di=36;40:ln=35;40:so=32;40:pi=33;40:ex=31;40:bd=34;46:cd=34;43:su=0;41:sg=0;46:tw=0;42:ow=0;43:' +export GREP_COLOR='1;33' + From 9e29eb06456932a444c7ab158fb6cd336ce437e2 Mon Sep 17 00:00:00 2001 From: Carlos Cardoso Date: Sun, 27 Apr 2014 00:41:52 -0300 Subject: [PATCH 6/9] update cadusk theme --- themes/cadusk.zsh-theme | 14 ++++++-------- 1 file changed, 6 insertions(+), 8 deletions(-) diff --git a/themes/cadusk.zsh-theme b/themes/cadusk.zsh-theme index 5a39721c5..1446d33fb 100644 --- a/themes/cadusk.zsh-theme +++ b/themes/cadusk.zsh-theme @@ -7,15 +7,15 @@ PROMPT2='%{$fg[white]%}$%{$reset_color%} ' RPROMPT='%{$(echotc UP 1)%} $(git_prompt_status) ${_return_status}%{$(echotc DO 1)%}' -local _current_dir="%F{208}%3~%{$reset_color%} " +local _current_dir="%F{208}%3~%f%{$reset_color%}" local _return_status="%{$fg[red]%}%(?..⍉)%{$reset_color%}" -local _hist_no="%{$fg[grey]%}%h%{$reset_color%}" +local _hist_no="%{$fg_bold[red]%}%h%{$reset_color%}" function _user_host() { me="%{$fg_bold[white]%}%n" if [[ -n $SSH_CONNECTION ]]; then - me="$me%{$fg_bold[cyan]%}@%m" + me="$me%{$fg_bold[black]%}@%m" fi echo "$me%b%{$reset_color%}" } @@ -26,15 +26,13 @@ else CARETCOLOR="white" fi -MODE_INDICATOR="%{$fg_bold[yellow]%}❮%{$reset_color%}%{$fg[yellow]%}❮❮%{$reset_color%}" - -ZSH_THEME_GIT_PROMPT_PREFIX="%{$reset_color%}(%{$fg_bold[yellow]%}" -ZSH_THEME_GIT_PROMPT_SUFFIX="%{$reset_color%})" +ZSH_THEME_GIT_PROMPT_PREFIX="%{$fg_bold[black]%}[" +ZSH_THEME_GIT_PROMPT_SUFFIX="%{$fg_bold[black]%}]%{$reset_color%}" ZSH_THEME_GIT_PROMPT_DIRTY="%{$fg[red]%}!%{$reset_color%}" ZSH_THEME_GIT_PROMPT_CLEAN="" # LS colors, made with http://geoff.greer.fm/lscolors/ -export LSCOLORS="exfxcxdxbxegedabagacad" +export LSCOLORS="Gxfxcxdxbxegedabagacad" export LS_COLORS='di=36;40:ln=35;40:so=32;40:pi=33;40:ex=31;40:bd=34;46:cd=34;43:su=0;41:sg=0;46:tw=0;42:ow=0;43:' export GREP_COLOR='1;33' From 17b6871994a4afd2ddbbdf650a8de171ed00b235 Mon Sep 17 00:00:00 2001 From: Carlos Cardoso Date: Mon, 28 Apr 2014 22:16:14 -0300 Subject: [PATCH 7/9] cadusk theme customization --- themes/cadusk.zsh-theme | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/themes/cadusk.zsh-theme b/themes/cadusk.zsh-theme index 1446d33fb..a69525f9b 100644 --- a/themes/cadusk.zsh-theme +++ b/themes/cadusk.zsh-theme @@ -1,7 +1,6 @@ # cadusk ZSH Theme - customized on top of avit theme -PROMPT=' -$(_user_host) ${_current_dir} $(git_prompt_info) +PROMPT='[$(_user_host) ${_current_dir}] $(git_prompt_info) $ ' PROMPT2='%{$fg[white]%}$%{$reset_color%} ' From ff0650d3f764db9613202613db35bcd33e42cc5b Mon Sep 17 00:00:00 2001 From: Carlos Cardoso Date: Fri, 2 May 2014 22:26:16 -0300 Subject: [PATCH 8/9] updated cadusk theme --- themes/cadusk.zsh-theme | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/themes/cadusk.zsh-theme b/themes/cadusk.zsh-theme index a69525f9b..320edb101 100644 --- a/themes/cadusk.zsh-theme +++ b/themes/cadusk.zsh-theme @@ -1,6 +1,7 @@ # cadusk ZSH Theme - customized on top of avit theme -PROMPT='[$(_user_host) ${_current_dir}] $(git_prompt_info) +PROMPT=' +[$(_user_host) ${_current_dir}] $(git_prompt_info) $ ' PROMPT2='%{$fg[white]%}$%{$reset_color%} ' From 62e09457f0dd8d5e1f17397f171f6d9bde2590fd Mon Sep 17 00:00:00 2001 From: Carlos Cardoso Date: Sat, 3 May 2014 01:28:23 -0300 Subject: [PATCH 9/9] disabled terminal cleanup on pager (less) exit --- templates/zshrc-linux.zsh | 12 ++++++++---- templates/zshrc-mac.zsh | 6 +++++- 2 files changed, 13 insertions(+), 5 deletions(-) diff --git a/templates/zshrc-linux.zsh b/templates/zshrc-linux.zsh index 2d63750da..71bfd99a2 100644 --- a/templates/zshrc-linux.zsh +++ b/templates/zshrc-linux.zsh @@ -35,16 +35,20 @@ DISABLE_VENV_CD="1" # Example format: plugins=(rails git textmate ruby lighthouse) plugins=(git gitfast tmux debian python virtualenvwrapper) -# Customize to your needs... -if [ -z "$LC_ALL" ]; then export LC_ALL=en_US.UTF-8; fi -if [ -z "$LANG" ]; then export LANG=en_US.UTF-8; fi - if [ -e $HOME/bin ]; then export PATH="$HOME/bin:$PATH"; fi if [ -e $HOME/.local/bin ]; then export PATH="$HOME/.local/bin:$PATH"; fi if [ -e $HOME/appengine ]; then export PATH="$HOME/appengine:$PATH"; fi if [ -e $HOME/.cabal/bin ]; then export PATH="$HOME/.cabal/bin:$PATH"; fi +# +if [ -z "$LC_ALL" ]; then export LC_ALL=en_US.UTF-8; fi +if [ -z "$LANG" ]; then export LANG=en_US.UTF-8; fi [ "$TERM" = "xterm" ] && TERM="xterm-256color" source $ZSH/oh-my-zsh.sh + +# Enviroment variables overwrite +export EDITOR='vim' +export LESS='-RX' + unsetopt correctall diff --git a/templates/zshrc-mac.zsh b/templates/zshrc-mac.zsh index 70bdd4312..176335ce6 100644 --- a/templates/zshrc-mac.zsh +++ b/templates/zshrc-mac.zsh @@ -38,7 +38,6 @@ plugins=(git gitfast postgres tmux python vim-override virtualenvwrapper) # User configuration if [ -e $HOME/bin ]; then export PATH="$HOME/bin:$PATH"; fi if [ -e /usr/local/bin ]; then export PATH="/usr/local/bin:$PATH"; fi -export EDITOR='vim' # Language configuration if [ -z "$LC_ALL" ]; then export LC_ALL=en_US.UTF-8; fi @@ -48,4 +47,9 @@ if [ -z "$LANG" ]; then export LANG=en_US.UTF-8; fi alias bu='brew update && brew upgrade' source $ZSH/oh-my-zsh.sh + +# Enviroment variables overwrite +export EDITOR='vim' +export LESS='-RX' + unsetopt correctall