-
Notifications
You must be signed in to change notification settings - Fork 72
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
Add globbing pattern matching for search_path (Replaces #179) #215
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can't get globbing to work. Used the examples in the unit tests locally and they did not produce a result. Need to provide some examples section in the README and a link to glob patterns
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can't get globbing to work. Used the examples in the unit tests locally and they did not produce a result. Need to provide some examples section in the README and a link to glob patterns
@kehoecj were you using double quotes around the pattern string? |
Even using double quotes I still can't seem to get this to work at all. Here's what I've tried and get no output:
If I point directly to the file it does run correctly:
|
@anya004 Any guidance on this? |
Hey @kehoecj ! To be honest, I was running it as Now I have also tried creating a standalone executable with Did I miss a step of creating an executable somewhere? I am new to go projects and would appreciate your guidance! Maybe you could also try running
|
@kehoecj have you had a chance to check the output? |
It's working now, approved! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM @anya004 , thanks for the PR!
Fixes #165
This PR adds support for glob patterns, controlled by a new
globbing
flag. When enabled (-globbing
), the tool will use glob pattern matching to locate files and directories.I decided to implement a flag so that the user is aware of the behaviour in case they have some unconventional filenames.
When globbing is enabled, matched paths are dynamically added to the
searchPath
array for further processing.