You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
60 lines
1.5 KiB
60 lines
1.5 KiB
if zrcautoload promptinit && promptinit 2>/dev/null ; then
|
|
source ~/.zsh/prompt_tba_setup
|
|
prompt_themes+=( tba )
|
|
prompt_themes=( "${(@on)prompt_themes}" )
|
|
prompt tba
|
|
else
|
|
print '-!- Notice: no promptinit available :('
|
|
fi
|
|
|
|
source $HOME/.zsh/commands
|
|
source $HOME/.zsh/programs
|
|
source $HOME/.zsh/zsh-autosuggestions/zsh-autosuggestions.zsh
|
|
case "$MTYPE" in
|
|
"PC")
|
|
source $HOME/.zsh/commands-pc
|
|
;;
|
|
"wlm")
|
|
source $HOME/.zsh/commands-server
|
|
# ssh-agent configuration
|
|
if [ -z "$(pgrep ssh-agent)" ]; then
|
|
rm -rf /tmp/ssh-*
|
|
eval $(ssh-agent -s) > /dev/null
|
|
else
|
|
export SSH_AGENT_PID=$(pgrep ssh-agent)
|
|
export SSH_AUTH_SOCK=$(find /tmp/ssh-* -name 'agent.*')
|
|
fi
|
|
if [[ "$(ssh-add -l)" == "The agent has no identities." ]]; then
|
|
ssh-add
|
|
fi
|
|
;;
|
|
"SERVER")
|
|
source $HOME/.zsh/commands-server
|
|
;;
|
|
esac
|
|
|
|
if [ -f "$HOME/.zsh/rbenv" -a -d "$HOME/.rbenv" ] ; then
|
|
source $HOME/.zsh/rbenv
|
|
fi
|
|
|
|
if [ -d "$HOME/bin" ] ; then
|
|
export PATH="$PATH:$HOME/bin"
|
|
fi
|
|
|
|
if [ -f "/usr/share/zsh/plugins/zsh-syntax-highlighting/zsh-syntax-highlighting.zsh" ] ; then
|
|
source /usr/share/zsh/plugins/zsh-syntax-highlighting/zsh-syntax-highlighting.zsh
|
|
elif [ -f "/usr/share/zsh-syntax-highlighting/zsh-syntax-highlighting.zsh" ] ; then
|
|
source /usr/share/zsh-syntax-highlighting/zsh-syntax-highlighting.zsh
|
|
else
|
|
printf "-!- zsh-syntax-highlighting not installed!"
|
|
fi
|
|
|
|
# completion
|
|
zstyle ':completion:*:*:kill:*:processes' command "ps -u $USER -o pid,user,comm,args -w -w"
|
|
|
|
export EDITOR='vim'
|
|
|
|
if [ ! -f '/var/run/crond.pid' ] ; then
|
|
sudo /etc/init.d/cron start
|
|
fi
|