mirror of
https://github.com/ohmyzsh/ohmyzsh.git
synced 2025-12-26 02:12:33 +01:00
Merge 5fe395d35a into 142c03dbd2
This commit is contained in:
commit
1fdbd07917
1 changed files with 6 additions and 2 deletions
|
|
@ -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
|
||||
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue