I have a repository where branch protection rules are enabled, requiring at least one pull-request review before merging.
However, I want to introduce an exception to this rule:
If a pull request only modifies files named config.json located anywhere in the repository (for example, service-a/config.json, env/prod/config.json, etc.)
Then the PR should not require manual review
Ideally, the PR should be auto-approved or allowed to merge without review
What I’m looking for:
Constraints / Context:
Branch restrictions are already enforced (1 review required)
The solution should be automated (Bitbucket Pipelines, etc.)
Preferably without weakening security for other file changes