Skip to content

Conversation

@le-lenn
Copy link
Contributor

@le-lenn le-lenn commented Dec 23, 2025

AI disclaimer

This PR was partly created with codex cli.

What changed

  • Add an explicit start path to the top-level directory scan: find . $find_args
    so BSD/macOS find doesn’t treat -mindepth/-maxdepth as illegal options when
    no path is provided.
  • Replace GNU-only -executable with portable -perm -u+x for runnable test
    discovery.

Why

  • BSD/macOS find requires a path argument; without it, options like -mindepth
    are parsed as invalid (BSD find(1) synopsis and option descriptions). GNU
    find allows no path, so this only fails on BSD/macOS.
  • -executable is documented in GNU findutils but is not listed in BSD find(1).
    -perm -u+x is supported by both and checks the user execute bit.

Flag details (with docs)

Behavior

  • Directory discovery still targets only direct child directories.
  • Script discovery still targets executable test scripts; the criteria now work
    on both GNU and BSD/macOS..

@m90
Copy link
Member

m90 commented Dec 23, 2025

This is brilliant, thanks! I assume you tested this on MacOS, it works as before for me in any case.

@m90 m90 merged commit 9bfcb25 into offen:main Dec 23, 2025
3 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.

2 participants