mirror of
https://github.com/ohmyzsh/ohmyzsh.git
synced 2026-03-13 03:12:21 +01:00
plugins/theme: change to 2-space indenting and detabify (per https://github.com/robbyrussell/oh-my-zsh/wiki/Coding-style-guide#general)
This commit is contained in:
parent
5ee54032da
commit
d7c9e16f03
1 changed files with 15 additions and 15 deletions
|
|
@ -1,24 +1,24 @@
|
|||
function theme
|
||||
{
|
||||
if [ -z "$1" ] || [ "$1" = "random" ]; then
|
||||
themes=($ZSH/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..."
|
||||
if [ -z "$1" ] || [ "$1" = "random" ]; then
|
||||
themes=($ZSH/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
|
||||
if [ -f "$ZSH_CUSTOM/$1.zsh-theme" ]
|
||||
then
|
||||
source "$ZSH_CUSTOM/$1.zsh-theme"
|
||||
else
|
||||
if [ -f "$ZSH_CUSTOM/$1.zsh-theme" ]
|
||||
then
|
||||
source "$ZSH_CUSTOM/$1.zsh-theme"
|
||||
else
|
||||
source "$ZSH/themes/$1.zsh-theme"
|
||||
fi
|
||||
source "$ZSH/themes/$1.zsh-theme"
|
||||
fi
|
||||
fi
|
||||
}
|
||||
|
||||
function lstheme
|
||||
{
|
||||
cd $ZSH/themes
|
||||
ls *zsh-theme | sed 's,\.zsh-theme$,,'
|
||||
cd $ZSH/themes
|
||||
ls *zsh-theme | sed 's,\.zsh-theme$,,'
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue