3

Since we have many repos in our account, we use Cross-Repository policies for default branch. However, a small number of repos needs a different policy.

Specifically, we have a group that are added as automatic reviewers: enter image description here

We would like to remove this group and use another group for a limited number of repos.

Is there a way to do that?

3
  • It looks like your question is specifically about using Azure. If so, you might want to tighten the tags here. I'm seeing the question in git where it makes no sense. Commented May 24, 2021 at 22:32
  • Git was actually auto suggested. I updated the title Commented May 25, 2021 at 8:03
  • Does this answer your question? How to exclude a repository from Cross Repo policies? Commented May 11, 2022 at 8:36

2 Answers 2

2

Here is the user voice for overwriting branch policies directly for certain repositories. Maybe it will be implemented in the future, but currently there are no way to do it directly.

However there is another way to do it which is also mentioned in MS documentation. You can simply allow for certain teams to bypass some policies in repo settings: How to set up user permission to bypass policies

  1. Select repository settings
  2. Select desired repository
  3. Select the team you want to grant this privilege
  4. Set up to Allow three marked fields

This does not solve op question for automatic reviewers, so this can also be worked arround by going to desired repository default branch and adding a different reviewer there. In this case it will be two reviewers, but when making a PR users could simply choose which reviewer they want

Sign up to request clarification or add additional context in comments.

Comments

1

How to turn off Cross-Repository policies for default branch for certain repos

I think is is impossible. So far, there is no such option to control which repos enable the setting and which do not under the policies.

As a workaround, you have to set the policies setting for each repo.

Besides, if this does not meet your requirement, you have to suggest a feature to the Team and they will handle your suggestion carefully.

1 Comment

That's a bummer.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.