# HG changeset patch # User zegervdv # Date 1414046715 -7200 # Node ID 49e483d88403c7ebd6d46865733c7f2a15d09a5c # Parent 71a5b250ad3ddffdaacae4f2f945b043199960ab Add autosuggestions to zsh diff -r 71a5b250ad3d -r 49e483d88403 .hgsub --- a/.hgsub Thu Oct 23 08:39:21 2014 +0200 +++ b/.hgsub Thu Oct 23 08:45:15 2014 +0200 @@ -63,3 +63,4 @@ vim/bundle/tmuxline = [git]https://github.com/edkolev/tmuxline.vim.git vim/bundle/unite-everything = [git]https://github.com/sgur/unite-everything.git tmux/plugins/tpm = [git]https://github.com/tmux-plugins/tpm +zsh/plugins/zsh-autosuggestions = [git]https://github.com/tarruda/zsh-autosuggestions diff -r 71a5b250ad3d -r 49e483d88403 .hgsubstate --- a/.hgsubstate Thu Oct 23 08:39:21 2014 +0200 +++ b/.hgsubstate Thu Oct 23 08:45:15 2014 +0200 @@ -63,3 +63,4 @@ 2c03d82a0e4662adf1e347487d73a9bf4bf6fdac vim/bundle/vimwiki 22fa4e57fa3b0e4c9a83de51717b621fe9ca8cd7 vim/bundle/vis ca033af7273894da4c7e25f64e33e7fc141ef3b2 vimwiki +cbb09638962aa2e0e655ab8428a5aead6e3cbda7 zsh/plugins/zsh-autosuggestions diff -r 71a5b250ad3d -r 49e483d88403 zshrc --- a/zshrc Thu Oct 23 08:39:21 2014 +0200 +++ b/zshrc Thu Oct 23 08:45:15 2014 +0200 @@ -12,6 +12,7 @@ source ~/.fzf.zsh source ~/.zsh/zsh-history-substring-search.zsh source ~/.zsh/z.sh +source ~/.zsh/plugins/zsh-autosuggestions/autosuggestions.zsh precmd() { if [[ -n "$TMUX" ]]; then @@ -20,4 +21,11 @@ fi } +# Enable autosuggestions automatically +zle-line-init() { + zle autosuggest-start +} +zle -N zle-line-init + + [[ -f ~/.zshrc.local ]] && source ~/.zshrc.local