Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: support glob pattern #172

Merged

Conversation

mannguyen0107
Copy link
Contributor

  • Add support for adding all files in a folder if "/*" is included in the given path. For example:
plug "$HOME/plugins/*"
  • For the original functionality I have removed the glob pattern matching there because it is currently not being used since we are only sourcing the 1st element return of initfiles array. Instead of creating a loop and be done with it, I decided to look for specific "*" included in the path then do a loop otherwise I just source the 1st element, keeping the original function intact

@wintermi wintermi self-assigned this Sep 3, 2023
fix: fix example message to clarify the use of this feature
- put back in place the `fpath` line
- fixed original functionality allowing the plugin `initfile` to have a different name from the plugin repository
Copy link
Member

@mamaraddio mamaraddio left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I still think this is an interesting feature, so I fixed a couple lines and we are good to go

zap.zsh Outdated
@@ -4,16 +4,25 @@ export ZSHRC="${ZDOTDIR:-$HOME}/.zshrc"
export ZAP_DIR="${XDG_DATA_HOME:-$HOME/.local/share}/zap"
export ZAP_PLUGIN_DIR="$ZAP_DIR/plugins"
export -a ZAP_INSTALLED_PLUGINS=()
fpath+="$ZAP_DIR/completion"
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Put back again the fpath addition line, please

@mamaraddio mamaraddio merged commit 5eb1556 into zap-zsh:master Apr 9, 2024
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants