-
Notifications
You must be signed in to change notification settings - Fork 0
/
zshrc
76 lines (65 loc) · 1.56 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
73
74
75
76
#
# Executes commands at the start of an interactive session.
#
# Authors:
# Sorin Ionescu <sorin.ionescu@gmail.com>
#
# Source Prezto
if [[ -s "${ZDOTDIR:-$HOME}/.zprezto/init.zsh" ]]; then
source "${ZDOTDIR:-$HOME}/.zprezto/init.zsh"
fi
# Bind custom key combinations
#bindkey \^U backward-kill-line
#zstyle ':completion:*' hosts off
# Configure the title for xterm sessions
DISABLE_AUTO_TITLE="true"
case $TERM in
screen*)
precmd () {
# TAB TITLE
printf '\ePtmux;\e\e]1;%s\a\e\\' "${PWD/#$HOME/~}"
# WINDOW TITLE
printf '\ePtmux;\e\e]2;%s\a\e\\' "${USER}@$(hostname -s)"
# TMUX TITLE
printf '\ek%s\e\\' "${PWD/#$HOME/~}"
}
;;
xterm*)
precmd () {
# TAB TITLE
printf '\e]1;%s\a' "${PWD/#$HOME/~}"
# WINDOW TITLE
printf '\e]2;%s\a' "${USER}@$(hostname -s)"
}
;;
esac
# Setup ZSH key bindings
bindkey \^U backward-kill-line
# Add new items to path from ~/.lib/paths
if [ -f ~/.lib/path_helper ]; then
. ~/.lib/path_helper
fi
# Add new SSH proxy functions
if [ -f ~/.lib/proxy ]; then
. ~/.lib/proxy
fi
# Add any new aliases to this file
if [ -f ~/.lib/aliases ]; then
. ~/.lib/aliases
fi
# Add new fixssh() function for terminal multiplexers
if [ -f ~/.lib/grabssh ]; then
. ~/.lib/grabssh
fi
# Add any local customizations
if [ -f ~/.localrc ]; then
. ~/.localrc
fi
# Load RVM if it is installed
if [ -s "${HOME}/.rvm/scripts/rvm" ]; then
. "${HOME}/.rvm/scripts/rvm"
fi
# Add new items to path from ~/.lib/paths
if [ -f ~/.lib/path_deduper ]; then
. ~/.lib/path_deduper
fi