Merge branch 'master' of github.com:jamesm-sitegen/oh-my-zsh

This commit is contained in:
Simon Gomizelj 2011-12-01 16:40:35 -05:00
commit 017e6f7803
4 changed files with 20 additions and 21 deletions

View file

@ -45,7 +45,7 @@ for plugin ($plugins); do
done done
local ZSH_THEME local ZSH_THEME
zstyle -a :omz theme ZSH_THEME zstyle -a :omz:style theme ZSH_THEME
# Load the theme # Load the theme
if [ "$ZSH_THEME" = "random" ] if [ "$ZSH_THEME" = "random" ]

View file

@ -1,6 +1,4 @@
local ssh_env=$HOME/.ssh/environment-$HOST function keychain_start_agent()
function start_agent()
{ {
local -a identities local -a identities
@ -15,23 +13,23 @@ function start_agent()
} }
function keychain() { function keychain() {
local ssh_env=$HOME/.ssh/environment-$HOST
case $1 in case $1 in
"start") ;; "start")
if [[ -f $ssh_env ]]; then
source $ssh_env >/dev/null
ps -p $SSH_AGENT_PID >/dev/null || keychain_start_agent
else
keychain_start_agent;
fi
;;
"kill") "kill")
ssh-agent -k echo "Stopping agent"
ssh-agent -k >/dev/null && [[ -f $ssh_env ]] && rm $ssh_env
;; ;;
esac esac
} }
zstyle -a :omz:plugins:keychain autostart state zstyle -a :omz:plugins:keychain autostart state
if [[ $state == "on" ]]; then [[ $state == "on" ]] && keychain start
if [[ -f $ssh_env ]]; then
source $ssh_env >/dev/null
ps -p $SSH_AGENT_PID >/dev/null || start_agent
else
start_agent;
fi
fi
unfunction start_agent
unset ssh_env

View file

@ -1,7 +1,7 @@
# Check /etc/zsh/zshrc for system defaults. # Check /etc/zsh/zshrc for system defaults.
ZSH_THEME="arch-blue" zstyle :omz:style theme "arch-blue"
plugins=(archlinux sprunge git github) plugins=(archlinux sprunge git github)
load_oh_my_zshell omz_init

View file

@ -1,6 +1,7 @@
ZSH=/usr/share/oh-my-zsh ZSH=/usr/share/oh-my-zsh
zstyle -a :omz theme "arch-blue" zstyle :omz:style theme "arch-blue"
plugins=(archlinux sprunge) plugins=(archlinux sprunge)
omz_init() { omz_init() {