diff --git a/runcoms/zpreztorc b/runcoms/zpreztorc index ae68a89..92c7074 100644 --- a/runcoms/zpreztorc +++ b/runcoms/zpreztorc @@ -39,7 +39,11 @@ zstyle ':prezto:load' pmodule \ 'utility' \ 'completion' \ 'history-substring-search' \ - 'prompt' + 'prompt' \ + 'fasd' \ + 'git' \ + 'ruby' \ + 'tmux' # # Autosuggestions @@ -74,7 +78,7 @@ zstyle ':prezto:module:editor' key-bindings 'emacs' # # Ignore submodules when they are 'dirty', 'untracked', 'all', or 'none'. -# zstyle ':prezto:module:git:status:ignore' submodules 'all' +zstyle ':prezto:module:git:status:ignore' submodules 'all' # # GNU Utility @@ -130,7 +134,7 @@ zstyle ':prezto:module:editor' key-bindings 'emacs' # Set the prompt theme to load. # Setting it to 'random' loads a random theme. # Auto set to 'off' on dumb terminals. -zstyle ':prezto:module:prompt' theme 'sorin' +zstyle ':prezto:module:prompt' theme 'pure' # Set the working directory prompt display length. # By default, it is set to 'short'. Set it to 'long' (without '~' expansion) @@ -141,6 +145,13 @@ zstyle ':prezto:module:prompt' theme 'sorin' # return codes. This is not supported by all prompts. # zstyle ':prezto:module:prompt' show-return-val 'yes' +# +# Ruby +# + +# Auto switch the Ruby version on directory change. +zstyle ':prezto:module:ruby:chruby' auto-switch 'yes' + # # Python # diff --git a/runcoms/zshenv b/runcoms/zshenv index 2dbf12a..946d433 100644 --- a/runcoms/zshenv +++ b/runcoms/zshenv @@ -9,3 +9,15 @@ if [[ ( "$SHLVL" -eq 1 && ! -o LOGIN ) && -s "${ZDOTDIR:-$HOME}/.zprofile" ]]; then source "${ZDOTDIR:-$HOME}/.zprofile" fi + +if command -v brew &> /dev/null; then + if [[ -s `brew --prefix`/share/chruby/chruby.sh ]]; then + source `brew --prefix`/share/chruby/chruby.sh + # source `brew --prefix`/share/chruby/auto.sh + chruby ruby + fi +fi + +if command -v direnv &> /dev/null; then + eval "$(direnv hook zsh)" +fi diff --git a/runcoms/zshrc b/runcoms/zshrc index 039b882..acf38fc 100644 --- a/runcoms/zshrc +++ b/runcoms/zshrc @@ -10,4 +10,17 @@ if [[ -s "${ZDOTDIR:-$HOME}/.zprezto/init.zsh" ]]; then source "${ZDOTDIR:-$HOME}/.zprezto/init.zsh" fi -# Customize to your needs... +export EDITOR=vim +export VISUAL=vim + +unsetopt correct # Don't autocorrect +setopt no_nomatch # Pass bad matches on +setopt no_share_history + +bindkey "\ep" history-beginning-search-backward +bindkey "\en" history-beginning-search-forward + +alias be='bundle exec' +alias tat='tmux new-session -As `basename $PWD`' + +[[ -s "$HOME/.zshrc.local" ]] && . "$HOME/.zshrc.local"