-
Notifications
You must be signed in to change notification settings - Fork 0
/
.zshrc
72 lines (58 loc) · 1.63 KB
/
.zshrc
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
source ~/.antigen.zsh
# Load the oh-my-zsh's library
antigen use oh-my-zsh
antigen bundle git
antigen bundle heroku
antigen bundle pip
antigen bundle command-not-found
# Highlighting
antigen bundle zsh-users/zsh-syntax-highlighting
antigen theme candy
antigen apply
# Uncomment the following line to display red dots whilst waiting for completion.
COMPLETION_WAITING_DOTS="true"
## User configuration
# Preferred editor for local and remote sessions
if [[ -n $SSH_CONNECTION ]]; then
export EDITOR='vim'
else
export EDITOR='nvim'
fi
if type nvim > /dev/null 2>&1; then
alias vim='nvim'
fi
# Include all important alias
if [ -f ~/.aliases ]; then
. ~/.aliases
fi
# You might not want this
export GOPATH=~/Programming/go
export PATH=$PATH:$(go env GOPATH)/bin
# Enable vim bindings
bindkey -v
# Zsh settings for history
HISTORY_IGNORE="(ls|[bf]g|exit|reset|clear|cd|cd ..|cd..)"
HISTSIZE=25000
HISTFILE=~/.zsh_history
SAVEHIST=100000
setopt INC_APPEND_HISTORY
setopt HIST_IGNORE_ALL_DUPS
setopt HIST_IGNORE_SPACE
setopt HIST_REDUCE_BLANKS
setopt HIST_VERIFY
# nf [-NUM] [COMMENTARY...] -- never forget last N commands
nf() {
local n=-1
[[ "$1" = -<-> ]] && n=$1 && shift
fc -lnt ": %Y-%m-%d %H:%M ${*/\%/%%} ;" $n | tee -a .neverforget
}
# Say how long a command took, if it took more than 30 seconds
export REPORTTIME=30
system_type=$(uname -s)
if [ "$system_type" = "Darwin" ]; then
# Colour output on Mac OS
export CLICOLOR=1
[ -f "/Users/alexander/.ghcup/env" ] && source "/Users/alexander/.ghcup/env" # ghcup-env
export PATH="/usr/local/opt/[email protected]/bin:$PATH"
PATH=$PATH:/Users/alexander/.local/bin/
fi