-
-
Notifications
You must be signed in to change notification settings - Fork 709
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
Allow no-commit-to-branch to block commits based on regex matching #375
Comments
Seems fine, let's use |
Sure, I'll re-work the PR. Just want to double check - do you see the example above becoming:
i.e. the branch and pattern args would become an OR match, as opposed to the two args being mutually exclusive and needing to do:
|
the first one sounds good 👍 |
marcjay
changed the title
Allow no-commit-to-branch to block commits based on wildcard matching
Allow no-commit-to-branch to block commits based on regex matching
Apr 20, 2019
via #376 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Hopefully not alone in wanting this functionality - our use case is we have multiple release branches (e.g.
release/1.0.0
,release/2.0.0
) and no commits should be made to these branches directly, only via pull requests.This would be to add wildcard matching, so that with
args: [--branch, master, --branch, release/*]
it would cause pre-commit to fail if a commit is attempted on any of:master
,release/1.0.0
orrelease/2.0.0
The text was updated successfully, but these errors were encountered: