]> Sergey Matveev's repositories - dotfiles.git/blobdiff - zsh/.zshrc
Updated zsh-syntax-highlighting
[dotfiles.git] / zsh / .zshrc
index 119bc385041c9ead3307be6f9d2240c8fc2fd1d4..4aa6a4ff9c01b87016eaa5bbfc87710b754ddf1e 100644 (file)
@@ -35,6 +35,8 @@ 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-pattern-search-backward
+
+HISTORY_IGNORE="(yt* *|t *|t|mmfileget *)"
 # }}}
 
 # Prompt {{{
@@ -57,18 +59,10 @@ preexec() {
 }
 
 precmd() {
-    print -n "\a"
+    printf "\a\033]2;\033\\"
 }
 # }}}
 
-# Tmux pane name {{{
-CTP()
-{
-    printf "\033]2;\033\\"
-}
-CTP
-# }}}
-
 # Aliases {{{
 alias l="ls -AF "
 alias ll="ls -AFl "
@@ -77,7 +71,7 @@ alias vi="vim"
 alias more="less"
 alias m="less "
 alias -g M="| less"
-alias mc="mc --nomouse ; CTP"
+alias mc="mc --nomouse"
 bindkey -s "\eOS" " popd\n" # F4
 
 f() {
@@ -88,7 +82,7 @@ f() {
 ssht() {
     ssh -C -t "$1" tmux attach -t0
 }
-alias sshnm='ssh -S none'
+alias sshnm="ssh -S none"
 # }}}
 
 # Git {{{
@@ -104,8 +98,7 @@ alias -g W="| wc -l"
 git_common="--oneline --abbrev-commit"
 alias Gl="git log $git_common --graph --decorate=short"
 alias Gr="git --no-pager log $git_common -n 20 | perl -ne 'print \"@~\$n \$_\"; \$n++'"
-alias Grr="git --no-pager log $git_common --graph -n 1024 | vi -c 'e ++enc=utf8' -"
-alias Grpck="git gc --prune=now ; git repack -a -d --depth=4095 --window=10240"
+alias Grr="git --no-pager log $git_common --graph -n 1024 | vi -c 'setlocal filetype=gitrebase buftype=nofile noswapfile' -"
 
 bindkey -s "\eOQ" " git status\n" # F2
 bindkey -s "\eOR" " git status --short\n" # F3
@@ -141,8 +134,8 @@ mailpath=(
     ~/mail/mbox"?Neue Nachrichten in =mbox"
     ~/mail/arbeit"?Neue Nachrichten in =arbeit"
 )
-alias arr="mutt -f =arbeit -e 'source ~/.mutt/accounts/stcnet.ru'"
-alias rss="mutt -f =rss"
+alias arr="mutt -f \=arbeit -e 'source ~/.mutt/accounts/stcnet.ru'"
+alias rss="mutt -f \=rss"
 bindkey -s "\eOP" " inc\n" # F1
 # }}}
 
@@ -151,6 +144,9 @@ autoload -U zcalc
 alias zc="zcalc"
 # }}}
 
+# Named directories {{{
+. ~/.zhashd
+# }}}
 
 # Completion {{{
 zstyle ":completion:*:functions" ignored-patterns "_*"
@@ -174,15 +170,18 @@ autoload -U complist
 ZSH_HIGHLIGHT_HIGHLIGHTERS=(main brackets)
 . ~/work/zsh-syntax-highlighting/zsh-syntax-highlighting.zsh
 typeset -A ZSH_HIGHLIGHT_STYLES
+ZSH_HIGHLIGHT_STYLES[assign]="fg=cyan"
+ZSH_HIGHLIGHT_STYLES[commandseparator]="fg=red"
+ZSH_HIGHLIGHT_STYLES[single-hyphen-option]="fg=green,bold"
+ZSH_HIGHLIGHT_STYLES[double-hyphen-option]="fg=green"
 ZSH_HIGHLIGHT_STYLES[globbing]="fg=magenta"
 ZSH_HIGHLIGHT_STYLES[history-expansion]="fg=magenta"
-ZSH_HIGHLIGHT_STYLES[commandseparator]="fg=red"
 ZSH_HIGHLIGHT_STYLES[redirection]="fg=red"
-ZSH_HIGHLIGHT_STYLES[assign]="fg=cyan"
+ZSH_HIGHLIGHT_STYLES[path]="fg=white,underline"
+ZSH_HIGHLIGHT_STYLES[path_pathseparator]="fg=white,bold,underline"
 # }}}
 
 # Autosuggestion {{{
 . ~/work/zsh-autosuggestions/zsh-autosuggestions.zsh
-ZSH_AUTOSUGGEST_HIGHLIGHT_STYLE="fg=6"
+ZSH_AUTOSUGGEST_HIGHLIGHT_STYLE="fg=cyan"
 # }}}
-