aboutsummaryrefslogtreecommitdiff
path: root/zsh/.zshrc
diff options
context:
space:
mode:
authoreug-vs <eugene@eug-vs.xyz>2021-09-10 00:26:04 +0300
committereug-vs <eugene@eug-vs.xyz>2021-09-10 00:26:04 +0300
commit928097912990c92dc7cd69c692374b1a5b4636e8 (patch)
tree748419709eca0c8101d399ef2ac5b8a1a03f3d6f /zsh/.zshrc
parentc2ff3597a5dd655f0e248612eb4e7190c656c6ab (diff)
downloaddotfiles-928097912990c92dc7cd69c692374b1a5b4636e8.tar.gz
refactor: move zsh to a separate stow package
Diffstat (limited to 'zsh/.zshrc')
-rw-r--r--zsh/.zshrc43
1 files changed, 43 insertions, 0 deletions
diff --git a/zsh/.zshrc b/zsh/.zshrc
new file mode 100644
index 0000000..76ed964
--- /dev/null
+++ b/zsh/.zshrc
@@ -0,0 +1,43 @@
+autoload -U colors && colors
+PS1="%B%{$fg[white]%}[%{$fg[cyan]%}%n%{$fg[white]%}@%{$fg[green]%}%M %{$fg[yellow]%}%~%{$fg[white]%}]%{$reset_color%}$%b "
+bindkey -e
+
+# History in cache directory:
+export HISTSIZE=10000
+export SAVEHIST=10000000
+export HISTFILE=~/.cache/zsh/history
+setopt HIST_IGNORE_ALL_DUPS
+setopt INC_APPEND_HISTORY
+setopt SHARE_HISTORY
+
+# Completion
+autoload -U compinit
+zstyle ':completion:*' menu select
+zmodload zsh/complist
+compinit
+_comp_options+=(globdots)
+
+# Edit line in vim with ctrl-e:
+autoload edit-command-line; zle -N edit-command-line
+bindkey '^e' edit-command-line
+
+# Aliases
+alias vi=nvim
+alias vim=nvim
+alias vf=vifm
+alias g=git
+alias t=task
+alias tw=timew
+alias s="sudo systemctl"
+
+# FZF
+source /usr/share/fzf/key-bindings.zsh
+source /usr/share/fzf/completion.zsh
+
+# Node version manager
+export NVM_DIR="$HOME/.nvm"
+[ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh" --no-use # This loads nvm
+[ -s "$NVM_DIR/bash_completion" ] && \. "$NVM_DIR/bash_completion" # This loads nvm bash_completion
+
+# Syntax highlighting, must be last
+source /usr/share/zsh/plugins/zsh-syntax-highlighting/zsh-syntax-highlighting.zsh