diff options
author | Aswath K <aswath.sana@gmail.com> | 2018-10-08 21:55:20 +0530 |
---|---|---|
committer | Marc Cornellà <marc.cornella@live.com> | 2018-10-08 18:25:20 +0200 |
commit | d9ea2604790d0ce0f7160b77bebe06c69766c06e (patch) | |
tree | d6b5c1661206101a83487a0bed0b7f15317be03b /plugins/themes/themes.plugin.zsh | |
parent | 999d3ddf4cb4f263e9ea27b7ca0b5617c4ed19cb (diff) | |
download | zsh-d9ea2604790d0ce0f7160b77bebe06c69766c06e.tar.gz zsh-d9ea2604790d0ce0f7160b77bebe06c69766c06e.tar.bz2 zsh-d9ea2604790d0ce0f7160b77bebe06c69766c06e.zip |
themes: add custom themes directory support to `lstheme` (#7236)
`lstheme` command used to list only the themes listed in `$ZSH/themes/` directory. This commit adds themes in `$ZSH_CUSTOM/themes/` also to the theme listings.
Diffstat (limited to 'plugins/themes/themes.plugin.zsh')
-rw-r--r-- | plugins/themes/themes.plugin.zsh | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/plugins/themes/themes.plugin.zsh b/plugins/themes/themes.plugin.zsh index 487e85689..2cd0ee327 100644 --- a/plugins/themes/themes.plugin.zsh +++ b/plugins/themes/themes.plugin.zsh @@ -19,6 +19,8 @@ function theme function lstheme { - cd $ZSH/themes - ls *zsh-theme | sed 's,\.zsh-theme$,,' + # Resources: + # http://zsh.sourceforge.net/Doc/Release/Expansion.html#Modifiers + # http://zsh.sourceforge.net/Doc/Release/Expansion.html#Glob-Qualifiers + print -l {$ZSH,$ZSH_CUSTOM}/themes/*.zsh-theme(N:t:r) } |