This commit is contained in:
GitHub Merge Button 2011-05-30 23:18:37 -07:00
commit 1fdbd07917

View file

@ -31,14 +31,18 @@ for config_file ($ZSH/custom/*.zsh) source $config_file
# Check for updates on initial load...
if [ "$ZSH_THEME" = "random" ]
then
themes=($ZSH/themes/*zsh-theme)
themes=($ZSH/themes/*zsh-theme $ZSH/custom/themes/*zsh-theme)
N=${#themes[@]}
((N=(RANDOM%N)+1))
RANDOM_THEME=${themes[$N]}
source "$RANDOM_THEME"
echo "[oh-my-zsh] Random theme '$RANDOM_THEME' loaded..."
else
source "$ZSH/themes/$ZSH_THEME.zsh-theme"
if [ -f $ZSH/custom/themes/$ZSH_THEME.zsh-theme ]; then
source $ZSH/custom/themes/$ZSH_THEME.zsh-theme
elif [ -f $ZSH/themes/$ZSH_THEME.zsh-theme ]; then
source $ZSH/themes/$ZSH_THEME.zsh-theme
fi
fi