arnaucube
arnaucube/configsPublic Self-hosted repository
configs/.zshrc
.zshrcRaw
 1# Set up the prompt
 2
 3autoload -Uz promptinit
 4promptinit
 5# prompt adam1
 6# prompt bart
 7
 8setopt histignorealldups sharehistory
 9
10# Use emacs keybindings even if our EDITOR is set to vi
11# bindkey -e
12
13# Keep 1000 lines of history within the shell and save it to ~/.zsh_history:
14HISTSIZE=1000
15SAVEHIST=1000
16HISTFILE=~/.zsh_history
17
18# Use modern completion system
19autoload -Uz compinit
20compinit
21
22zstyle ':completion:*' auto-description 'specify: %d'
23zstyle ':completion:*' completer _expand _complete _correct _approximate
24zstyle ':completion:*' format 'Completing %d'
25zstyle ':completion:*' group-name ''
26zstyle ':completion:*' menu select=2
27eval "$(dircolors -b)"
28zstyle ':completion:*:default' list-colors ${(s.:.)LS_COLORS}
29zstyle ':completion:*' list-colors ''
30zstyle ':completion:*' list-prompt %SAt %p: Hit TAB for more, or the character to insert%s
31zstyle ':completion:*' matcher-list '' 'm:{a-z}={A-Z}' 'm:{a-zA-Z}={A-Za-z}' 'r:|[._-]=* r:|=* l:|=*'
32zstyle ':completion:*' menu select=long
33zstyle ':completion:*' select-prompt %SScrolling active: current selection at %p%s
34zstyle ':completion:*' use-compctl false
35zstyle ':completion:*' verbose true
36
37zstyle ':completion:*:*:kill:*:processes' list-colors '=(#b) #([0-9]#)*=0=01;31'
38zstyle ':completion:*:kill:*' command 'ps -u $USER -o pid,%cpu,tty,cputime,cmd'
39
40source ~/.sh_alias
41
42# to see the available colours: for COLOR in {1..255}; do echo -en "\e[38;5;${COLOR}m${COLOR} "; done; echo;
43
44PROMPT='%B%F{48}%n%F{white}:%F{39}%0~%f%b$ '
45
46# git
47autoload -Uz vcs_info
48precmd_vcs_info() { vcs_info }
49precmd_functions+=( precmd_vcs_info )
50setopt prompt_subst
51RPROMPT=\$vcs_info_msg_0_%F{244}%*%f
52zstyle ':vcs_info:git:*' formats '%F{207}(%b)%f'
53zstyle ':vcs_info:*' enable git
54
55# go
56export PATH=$PATH:/usr/local/go/bin
57export PATH=$PATH:~/go/bin
58export GOPATH=$HOME/go
59alias goimports="~/go/bin/goimports"
60alias golint="~/go/bin/golint"
61# alias benchcmp="~/go/bin/benchcmp"
62# export GOPHERJS_GOROOT="$(go1.12.16 env GOROOT)"
63
64# rust
65export PATH="$HOME/.cargo/bin:$PATH"
66
67export EDITOR=vim
68export LC_ALL="en_US.UTF-8"
69
70[ -f ~/.fzf.zsh ] && source ~/.fzf.zsh