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

Single asterisk matches files in subfolders #44

Closed
pocmo opened this issue Mar 7, 2024 · 3 comments
Closed

Single asterisk matches files in subfolders #44

pocmo opened this issue Mar 7, 2024 · 3 comments

Comments

@pocmo
Copy link

pocmo commented Mar 7, 2024

In this example:

owners = CodeOwners("""
    docs/generator/build.py @octocat
    
    # The `docs/*` pattern will match files like
    # `docs/getting-started.md` but not further nested files like
    # `docs/build-app/troubleshooting.md`.
    docs/*  @doctocat
    """)

owners.of('docs/generator/build.py')

I'd expect the owner to be octocat but the library returns doctocat. According to the GitHub documentation example (and as mentioned in the comment), the single asterisk should not match nested files.

@pocmo
Copy link
Author

pocmo commented Mar 7, 2024

I just found #32 and #33. It looks like this fix may have never been released?

@sbdchd
Copy link
Owner

sbdchd commented Mar 7, 2024

Oops! I've released a new version!

@pocmo
Copy link
Author

pocmo commented Mar 11, 2024

Awesome, thank you! This is working for me now. :)

@pocmo pocmo closed this as completed Mar 11, 2024
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

2 participants