Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
O
oh-my-zsh
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
JIRA
JIRA
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
github
oh-my-zsh
Commits
40096685
Commit
40096685
authored
Mar 02, 2020
by
Marc Cornellà
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
random: remove random theme from possible themes to choose from
...preventing an infinite loop.
parent
480f1ecd
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
2 deletions
+2
-2
random.zsh-theme
themes/random.zsh-theme
+2
-2
No files found.
themes/random.zsh-theme
View file @
40096685
...
@@ -3,7 +3,7 @@ typeset -Ua themes
...
@@ -3,7 +3,7 @@ typeset -Ua themes
if [[ "${(t)ZSH_THEME_RANDOM_CANDIDATES}" = array && ${#ZSH_THEME_RANDOM_CANDIDATES[@]} -gt 0 ]]; then
if [[ "${(t)ZSH_THEME_RANDOM_CANDIDATES}" = array && ${#ZSH_THEME_RANDOM_CANDIDATES[@]} -gt 0 ]]; then
# Use ZSH_THEME_RANDOM_CANDIDATES if properly defined
# Use ZSH_THEME_RANDOM_CANDIDATES if properly defined
themes=($
ZSH_THEME_RANDOM_CANDIDATES
)
themes=($
{(@)ZSH_THEME_RANDOM_CANDIDATES:#random}
)
else
else
# Look for themes in $ZSH_CUSTOM and $ZSH and add only the theme name
# Look for themes in $ZSH_CUSTOM and $ZSH and add only the theme name
themes=(
themes=(
...
@@ -12,7 +12,7 @@ else
...
@@ -12,7 +12,7 @@ else
"$ZSH"/themes/*.zsh-theme(N:t:r)
"$ZSH"/themes/*.zsh-theme(N:t:r)
)
)
# Remove blacklisted themes from the list
# Remove blacklisted themes from the list
for theme in ${ZSH_THEME_RANDOM_BLACKLIST[@]}; do
for theme in
random
${ZSH_THEME_RANDOM_BLACKLIST[@]}; do
themes=("${(@)themes:#$theme}")
themes=("${(@)themes:#$theme}")
done
done
fi
fi
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment