How to make Build Validation within the branch policy is controllable, developer can turn it on/off when create the PR?

Karmel Naser 0 Reputation points
2023-05-04T06:46:14.9766667+00:00

How to make Build Validation within the branch policy is controllable?

So developer can turn this build validation on/off when create the PR.

Not Monitored
Not Monitored
Tag not monitored by Microsoft.
37,114 questions
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. SwathiDhanwada-MSFT 18,136 Reputation points
    2023-05-04T07:44:28.2566667+00:00

    @Karmel Naser Welcome to Microsoft Q & A Community Forum. Kindly Azure Devops questions are not supported on this forum. For expert assistance, reach out to the contacts listed in this document.

    That being said, to make Build Validation within the branch policy controllable, you can enable the "Bypass policies when completing pull request" option in the branch policy settings. This option allows developers to bypass the branch policy when completing a pull request.

    To enable this option, follow these steps:

    1. Go to the branch policy settings for the branch you want to configure.
    2. Under the "Policy" section, select "Build validation".
    3. Click on the "Edit" button to edit the policy.
    4. Under the "General" section, enable the "Bypass policies when completing pull request" option.
    5. Save the changes.

    With this option enabled, developers can choose to bypass the build validation policy when creating a pull request. They can do this by selecting the "Bypass" option when creating the pull request.

    Please note that enabling this option can reduce the effectiveness of your branch policies, so use it with caution.

    Reference document : https://learn.microsoft.com/en-us/azure/devops/repos/git/branch-policies?view=azure-devops&tabs=browser#bypass-branch-policies

    0 comments No comments