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

Support dot glob option #350

Open
timhirsh opened this issue Jan 6, 2023 · 0 comments
Open

Support dot glob option #350

timhirsh opened this issue Jan 6, 2023 · 0 comments

Comments

@timhirsh
Copy link

timhirsh commented Jan 6, 2023

Problem

I'm trying to match all files with the .yml extension. Some are contained in hidden directories that are arbitrarily nested. Eg:

path/to/.hiddenDir/file.yml

or

path/to/.hiddenFile.yml

Neither case above would be captured by the **/*.yml path in my include config.

Request

Please allow for more flexible matching of hidden files & directories. For example, node-glob supports an option to treat dots as normal characters, which would make it trivial to handle the situations above using a single pattern instead of multiple variations that require knowledge of the directory structure. I'd like for file extension matching to be agnostic of directory structure so that license checking isn't accidentally missed in newly added areas of the repo.

Thanks!

chiphogg pushed a commit to aurora-opensource/au that referenced this issue Jan 6, 2023
### Summary

I noticed we aren't enforcing license checking on any of our GitHub
workflow files. The reason is that the generic glob pattern we're using
(`**/*.yml`) doesn't match anything in hidden directories. I submitted a
feature request
[here](viperproject/check-license-header#350)
to make this more flexible. In the meantime, explicitly list out
`.github` in the config.

### Test Plan
* update the config first, see the license check
[fail](https://github.com/aurora-opensource/au/actions/runs/3857899619/jobs/6575810317)
for `clang-format-lint`
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

No branches or pull requests

1 participant