Skip to content

fix: Probot's use of ** aligns with Github's and matches paths like .github/X and abc/.env#42

Merged
ethanwharris merged 1 commit into
Lightning-AI:masterfrom
dhedey:david/dot-true-minimatch
May 13, 2026
Merged

fix: Probot's use of ** aligns with Github's and matches paths like .github/X and abc/.env#42
ethanwharris merged 1 commit into
Lightning-AI:masterfrom
dhedey:david/dot-true-minimatch

Conversation

@dhedey
Copy link
Copy Markdown

@dhedey dhedey commented May 13, 2026

Context

GitHub Actions' paths: filter uses minimatch with dot: true. Without it, patterns like ** silently skip dot-prefixed paths — so a subproject keyed on paths: ["**"] won't activate for a PR that only touches files under .github/, src/.foo, etc., even though the intent of ** is "match everything".

We hit this on a PR that modified only files under .github/, where our general lint subproject failed to activate. Working around it in checkgroup.yml requires enumerating every dot-segment permutation (**, .*, .*/**, **/.*, **/.*/**) and still doesn't cover paths with multiple non-adjacent dot segments. Fixing at the matcher is the right place.

Change

Pass dot: true to minimatch in matchFilenamesToSubprojects.

Notes

  • Risks: ** patterns match more things — same patterns activate subprojects for more PRs, never fewer. Net effect on consumers is stricter merge gating, not weaker. And aligns with how .github paths work. So I think this is a good change.
  • Verification: Tested with the rebuilt dist/. A subproject keyed on paths: ["**"] now activates for inputs like .gitignore, .github/workflows/foo.yml, my-project/.eslintrc, my-project/dot-config-staging — none of which it activated for before.

Aligns the checkgroup subproject matcher with GitHub Actions' own
`paths:` filter, which uses minimatch with `dot: true`. Without it,
patterns like `**` silently fail to match paths containing dot-
prefixed segments — so a subproject keyed on `paths: ["**"]` won't
activate for a PR that only modifies files under `.github/` or
similar dot directories, even though the intent of `**` is "match
everything".

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@dhedey dhedey changed the title fix: pass dot:true to minimatch in subproject path matching fix: Probot's use of ** aligns with Github's and matches paths like .github/X and abc/.env May 13, 2026
@ethanwharris ethanwharris merged commit 08fa537 into Lightning-AI:master May 13, 2026
2 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