]> Sergey Matveev's repositories - dotfiles.git/blobdiff - zsh/.zshrc
History pattern searching seems more convenient
[dotfiles.git] / zsh / .zshrc
index 9a783b766cac4515f9de9c232e96754e585c3de1..056f919104aebeeee3bb5d90d750be2f277b80e9 100644 (file)
@@ -7,6 +7,9 @@ setopt INTERACTIVE_COMMENTS
 setopt GLOB_STAR_SHORT GLOB_DOTS EXTENDED_GLOB
 setopt NO_NOMATCH
 setopt AUTO_PUSHD PUSHD_IGNORE_DUPS
+
+setopt RM_STAR_SILENT
+export LISTMAX=9999
 # }}}
 
 # Vi mode {{{
@@ -31,7 +34,7 @@ zle -N history-beginning-search-backward-end history-search-end
 zle -N history-beginning-search-forward-end history-search-end
 bindkey "^[[A" history-beginning-search-backward-end
 bindkey "^[[B" history-beginning-search-forward-end
-bindkey "^R" history-incremental-search-backward
+bindkey "^R" history-incremental-pattern-search-backward
 # }}}
 
 # Prompt {{{
@@ -96,6 +99,7 @@ alias Gd="git diff"
 alias Gs="git show"
 alias Gm="git diff --name-only --diff-filter=M"
 alias Gam="git commit --amend"
+alias -g W="| wc -l"
 
 git_common="--oneline --abbrev-commit"
 alias Gl="git log $git_common --graph --decorate=short"
@@ -114,7 +118,7 @@ LESS_COLORED="less --RAW-CONTROL-CHARS"
 g() {
     $GREP ${=GREP_ARGS} $@ | ${=LESS_COLORED}
 }
-gS() {
+GS() {
     $GREP ${=GREP_ARGS} $@ | sort --numeric-sort | ${=LESS_COLORED}
 }
 alias -g G="| $GREP --color"
@@ -158,7 +162,6 @@ zstyle ":completion:*" completer _mycomp _parameters
 autoload -U compinit ; compinit -d /tmp/.zcompdump
 zstyle ":completion:*:default" list-colors ""
 autoload -U complist
-export LISTMAX=9999
 # }}}
 
 # Highlighting {{{