zgen icon indicating copy to clipboard operation
zgen copied to clipboard

Failed to load multiple zsh-files in single repo

Open denysdovhan opened this issue 7 years ago • 1 comments

I'm trying to load pure zsh-theme. It contains two primary files with different extensions:

  • async.zsh
  • pure.plugin.zshpure.zsh

The problem is that with these checkings, zgen finds only pure.plugin.zsh and loads only this file, without async.zsh. It jumps in this condition and ignores all of following ones:

# ... L364-L366
 elif -zgen-path-contains "${location}" ".plugin.zsh" ; then
        for script (${location}/*\.plugin\.zsh(N)) -zgen-source "${script}"
# ...

That's why I get this in my init.zsh:

# ...
source "/Users/denysdovhan/.zgen/sindresorhus/pure-master/pure.plugin.zsh"
# ...

# ...

denysdovhan avatar May 03 '17 06:05 denysdovhan

I know this is an old issue but for cases like this, from my understanding and testing you can do something like the following:

zgen load sindresorhus/pure async.zsh
zgen load sindresorhus/pure

Or use upstream zsh-async like some of the options documented at https://github.com/sindresorhus/pure#integration:

zgen load mafredri/zsh-async
zgen load sindresorhus/pure

star-szr avatar Dec 04 '19 22:12 star-szr