2012-01-31 23:37:51 -05:00
|
|
|
#
|
2012-09-03 16:38:18 -04:00
|
|
|
# Executes commands at the start of an interactive session.
|
2012-01-31 23:37:51 -05:00
|
|
|
#
|
|
|
|
# Authors:
|
|
|
|
# Sorin Ionescu <sorin.ionescu@gmail.com>
|
|
|
|
#
|
|
|
|
|
2012-09-03 16:08:39 -04:00
|
|
|
# Source Prezto.
|
2012-09-03 16:13:53 -04:00
|
|
|
if [[ -s "${ZDOTDIR:-$HOME}/.zprezto/init.zsh" ]]; then
|
|
|
|
source "${ZDOTDIR:-$HOME}/.zprezto/init.zsh"
|
|
|
|
fi
|
2011-07-17 20:15:51 -04:00
|
|
|
|
2009-09-07 09:11:34 -07:00
|
|
|
# Customize to your needs...
|
2016-04-18 06:11:41 -04:00
|
|
|
|
2016-09-24 07:53:36 -04:00
|
|
|
[[ -s $(brew --prefix)/etc/profile.d/autojump.sh ]] && . $(brew --prefix)/etc/profile.d/autojump.sh
|
2016-04-18 06:11:41 -04:00
|
|
|
|
|
|
|
|
|
|
|
source ~/.fzf.zsh
|
2016-04-30 09:10:07 -04:00
|
|
|
[[ -s $(brew --prefix)/etc/profile.d/autojump.sh ]] && . $(brew --prefix)/etc/profile.d/autojump.sh
|
2016-04-18 06:11:41 -04:00
|
|
|
|
2016-09-24 07:53:36 -04:00
|
|
|
|
|
|
|
fasd_cache="$HOME/.fasd-init-zsh"
|
|
|
|
if [ "$(command -v fasd)" -nt "$fasd_cache" -o ! -s "$fasd_cache" ]; then
|
|
|
|
fasd --init posix-alias zsh-hook zsh-ccomp zsh-ccomp-install >| "$fasd_cache"
|
|
|
|
fi
|
|
|
|
source "$fasd_cache"
|
2016-09-25 07:29:32 -04:00
|
|
|
unset fasd_cache
|
|
|
|
|
2016-10-26 06:55:52 -04:00
|
|
|
export PATH=~/.local/bin:$PATH
|
2017-05-29 08:43:18 -04:00
|
|
|
|
|
|
|
# timing the commands
|
|
|
|
function ts_preexec() {
|
|
|
|
timer=${timer:-$SECONDS}
|
|
|
|
}
|
|
|
|
add-zsh-hook preexec ts_preexec
|
|
|
|
|
|
|
|
function ts_precmd() {
|
|
|
|
if [ $timer ]; then
|
|
|
|
timer_show=$(($SECONDS - $timer))
|
|
|
|
export RPROMPT="%t %F{cyan}${timer_show}s %{$reset_color%}"
|
|
|
|
unset timer
|
|
|
|
fi
|
|
|
|
}
|
|
|
|
add-zsh-hook precmd ts_precmd
|
|
|
|
|