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

feat(platform/azure): Allow to bypass certain policies for auto-merge #33626

Open
wants to merge 3 commits into
base: main
Choose a base branch
from

Conversation

janicmikes
Copy link

@janicmikes janicmikes commented Jan 15, 2025

Changes

This allows to use bypass functionality of Azure DevOps to provide a seamless auto-merge even if some policies are not met.

Policies one might want to bypass:

  • Require at least n reviewers (might also exclude the user of the last push)
  • Require specific reviewers (code owners)
  • Require work items to be linked (related to the config azureWorkItemId)
  • Require builds to pass (bound to the ignoreTests config)
  • Any other custom defined policies (UUID required)

Context

Automatic Merges for Azure DevOps might not be done (using merge) if some policies prevent the pr from being merged.
This can be bypassed by using the bypass policy option when completing the pull-request.

The thing is, that any other policy, not to be bypassed will prevent the bypass from being used.

Documentation (please check one with an [x])

  • I have updated the documentation, or
  • No documentation update is required

How I've tested my work (please select one)

I have verified these changes via:

  • Code inspection only, or
  • Newly added/modified unit tests, or
  • No unit tests but ran on a real repository, or
  • Both unit tests + ran on a real repository

@janicmikes janicmikes changed the title feat: Allow to bypass certain policies in azure DevOps feat(platform/azure): Allow to bypass certain policies in azure DevOps Jan 15, 2025
@janicmikes janicmikes changed the title feat(platform/azure): Allow to bypass certain policies in azure DevOps feat(platform/azure): Allow to bypass certain policies in azure DevOps for auto-merge Jan 15, 2025
@viceice viceice changed the title feat(platform/azure): Allow to bypass certain policies in azure DevOps for auto-merge feat(platform/azure): Allow to bypass certain policies for auto-merge Jan 17, 2025
@janicmikes janicmikes force-pushed the feat/ado-bypass-for-automerge branch from 55d0b62 to 87ec451 Compare January 17, 2025 21:29
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

Successfully merging this pull request may close these issues.

1 participant