-
Notifications
You must be signed in to change notification settings - Fork 0
/
.zshrc
69 lines (53 loc) · 1.66 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
export PATH="$HOME/.gem/ruby/1.9.1/bin:/usr/local/bin:$PATH:/usr/local/sbin:/sbin"
if [[ "$OSTYPE" == darwin* && -f "/etc/zshenv" && ! -f "/etc/zprofile" ]]; then
# This fixes ZSH paths for MacVim
# From http://stackoverflow.com/a/7382033/1311454
sudo mv "/etc/zshenv" "/etc/zprofile"
fi
ZSH=$HOME/.oh-my-zsh
ZSH_CUSTOM=$HOME/.zsh
ZSH_THEME="twilight"
DISABLE_AUTO_TITLE="true"
skip_global_compinit=1
plugins=(ruby osx lol nyan vi-mode)
source $ZSH/oh-my-zsh.sh
if [ -f "$HOME/.certs/cacert.pem" ]; then
export GIT_SSL_CAINFO="$HOME/.certs/cacert.pem"
fi
export GNUPGHOME="$(readlink "$HOME/.gnupg")"
bindkey -v
set -o vi
bindkey "^W" backward-kill-word
bindkey "^H" backward-delete-char
bindkey "^U" backward-kill-line
bindkey "^?" backward-delete-char
function zle-line-init zle-keymap-select {
RPS1="${${KEYMAP/vicmd/-- NORMAL --}/(main|viins)/}"
RPS2=$RPS1
zle reset-prompt
}
zle -N zle-line-init
zle -N zle-keymap-select
mvim=/usr/local/bin/mvim
if [ -f $mvim ]; then
alias vim="$mvim -v"
alias vimdiff="$mvim -v -d"
alias mvim="$mvim --remote-tab-silent"
export EDITOR="mvim -v"
else
export EDITOR="vim"
fi
if [ -f "/sys/class/thermal/thermal_zone0/temp" ]; then
temp="/sys/class/thermal/thermal_zone0/temp"
elif [ -f "/proc/acpi/thermal_zone/THRM/temperature" ]; then
temp="/proc/acpi/thermal_zone/THRM/temperature"
fi
if [ -n "$temp" ]; then
alias temp="echo \"\$(cat /sys/class/thermal/thermal_zone0/temp | sed 's/.\{3\}$//') *C\""
fi
alias sgit="sudo -s git"
alias less="less -FXRS"
precmd () {print -Pn "\e]2; %~/ \a"}
preexec () {print -Pn "\e]2; %~/ \a"}
### Added by the Heroku Toolbelt
export PATH="/usr/local/heroku/bin:$PATH"