How can we enforce mandatory reviews in GitHub but still allow Maven release builds from CI?

我是研究僧i 提交于 2019-12-21 20:13:50

问题


We would like to use mandatory code reviews on pull requests in GitHub Enterprise 2.10 (using the "Require pull request reviews before merging" feature in the repository protected branch settings).

However, when we enable this feature, Maven release builds fail, since the release plugin tries to push the new SNAPSHOT version to the repository using the credentials of the user that runs the TeamCity release build.

Has anyone come up with an approach that works for this? Our requirements are:

  • Require code reviews for normal commits/pull requests
  • Allow automated release builds to commit the updated POM versions
  • Have all commits done by specific non-shared user accounts

回答1:


I found this answer on a related question: https://stackoverflow.com/a/47006088

My impression is that if you leave the "include administrators" checkbox unchecked, then you can use a repository owner with the release plugin. The trade off is you would then rely on discipline from your developers who are repository owners to not skip the review process.



来源:https://stackoverflow.com/questions/47286021/how-can-we-enforce-mandatory-reviews-in-github-but-still-allow-maven-release-bui

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!