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

any-glob-all-files does not working intuitevely #731

Closed
jnewb1 opened this issue Dec 20, 2023 · 4 comments
Closed

any-glob-all-files does not working intuitevely #731

jnewb1 opened this issue Dec 20, 2023 · 4 comments
Assignees
Labels
bug Something isn't working

Comments

@jnewb1
Copy link

jnewb1 commented Dec 20, 2023

there is currently no way to apply the "CI" label with the following rule

any-glob-all-files: [Jenkinsfile, .github/**]

when a PR which changes both Jenkinsfile and github actions files

open PR to fix: #714

@jnewb1 jnewb1 added bug Something isn't working needs triage labels Dec 20, 2023
@IvanZosimov
Copy link
Contributor

Hi, @jnewb1 👋 Thanks for the issue and PR, we will take a look.

@IvanZosimov
Copy link
Contributor

IvanZosimov commented Dec 22, 2023

Hi, @jnewb1, I believe that for your particular use case the glob's syntax of grouping conditions: {a,b,c} fits well. What I mean by that is:

any-glob-all-files: "{Jenkinsfile,.github/**}"

Could you, please, check that logic of this grouping is what you want to achieve and ping me back?

@IvanZosimov IvanZosimov self-assigned this Dec 23, 2023
@jnewb1
Copy link
Author

jnewb1 commented Dec 28, 2023

Hi, @jnewb1, I believe that for your particular use case the glob's syntax of grouping conditions: {a,b,c} fits well. What I mean by that is:


any-glob-all-files: "{Jenkinsfile,.github/**}"

Could you, please, check that logic of this grouping is what you want to achieve and ping me back?

Thank you, this syntax works for my use case, though I think it is less readable

@jnewb1 jnewb1 closed this as not planned Won't fix, can't repro, duplicate, stale Dec 28, 2023
@dfandrich
Copy link
Contributor

That that {} syntax documented anywhere? I couldn't find it. It's certainly not intuitive, and any-glob-all-files is still misnamed; it should be one-glob-all-files.

dfandrich added a commit to curl/curl that referenced this issue Dec 29, 2023
Despite its name, this atom acts like one-glob-to-all-files and a
different syntax with braces must be used to get
any-glob-to-all-files semantics. Unfortunately, this makes the file
completely unreadable.

Ref: actions/labeler#731
dfandrich added a commit to dfandrich/labeler that referenced this issue Dec 29, 2023
This test verifies that the glob brace syntax will match any glob
against all files. Document that any-glob-to-all-files means any single
glob. This reduces the ambiguity that caused actions#731 and other issues to be
opened. Also, fix an any-glob-to-any-file example so it actually matches
within the entire repository.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants