![REVIEWER REVIEWER]()
看来github对于合并工作流甚至是git-flow可能都是有用的,但是对于rebase工作流可能很难维护,这是一个合理的假设吗?我可以考虑将Atlassian Stash用作重新设计工作流的更好工具吗? 解决方案如何在GitHub中禁用拉取请求?到目前为止(2020年第二季度):不可能. 2020年9月更新,此问题在评论中指出 到 GitHub上的操作"Repo Lockdown" :它可以帮助防止任何新的PR GitHub存储库.十月. 2020:" GitHub动作:微调对外部动作的访问";意味着您可以禁用将创建PR(或对存储库产生任何其他影响)的外部GitHub Action 阿敏塞巴斯蒂安在 GitHub第1191版我制作了一个新应用,该应用可以立即关闭并锁定新的和现有的问题或请求,还支持发布评论和标签.它非常适合前叉和后视镜,您可以根据自己的喜好对其进行配置 dessant/repo-lockdown ,其中.github/lockdown.yml包括# Lock issues and pull requestslock: true# Limit to only `issues` or `pulls`# only: pull其他解决方法:请注意(考虑到OP自2015年1月起的日期): 自2015年9月起,您可以保护分支机构在GitHub存储库中.这意味着一个受保护的分支: 不能用力推 无法删除 在需要的状态检查之前,不能将更改合并到其中通过 直到必要的评论已获批准 无法编辑或无法从网络上载文件自2016年10月以来,您可以 取消评论但是,此要求有时会在没有充分理由的情况下阻止您的团队前进.如果有人留下要求更改的评论,然后休假或遇到计算机问题,即使您已经解决了审阅者的疑虑,您的拉取请求也可能会被封锁数天.这将取消阻止您的拉取请求,使您可以自由地合并它!I am trying to understand how will I be able to disable "pull requests" in github.Question 1:We are trying to use the rebase workflow and that means using pull requests can be harmful if that isn't a fast forward push.One Solution: Setup branch permissions for the branches where I want to disable pull request. Or add me as the reviewer to anything that goes into master.Question 2:So that begs the question, can I setup branch permissions in github ?? Can I add myself as a reviewer for any change that wants to get into master ?Question 3:Github has definitely removed pre-receive hooks, so how can I do any enforcements before the source hits the server ? pre-commit hooks can be done, but at the same time can be pain.I had asked a similar question here: Commit message hook on githubIt seems github could be useful for the merge workflow or even git-flow, but it can be hard to maintain for the rebase workflow, is that a fair assumption ?Can I consider atlassian Stash as a better tool for the rebase workflow ? 解决方案How to disable pull requests in GitHub?So far (Q2 2020): not possible.Update Sept. 2020, this "dear-github" issue point out in the comments to the GitHub Action "Repo Lockdown": it can help prevent any new PR on a GitHub repository.Oct. 2020: "GitHub Actions: Fine-tune access to external actions" means that you can disable external GitHub Action that would create PR (or have any other effect on your repository)Armin Sebastian suggests in GitHub issue 1191I've made a new app that immediately closes and locks new and existing issues or pull requests and also supports posting a comment and labeling.It is perfect for forks and mirrors, and you can configure it to your likingdessant/repo-lockdown, with a .github/lockdown.yml including# Lock issues and pull requestslock: true# Limit to only `issues` or `pulls`# only: pullOther workaround:Note that (considering the OP dates from January 2015):since Sept 2015, you can protect branches in a GitHub repo.That means a protected branch:Can't be force pushedCan't be deletedCan't have changes merged into it until required status checks passCan't have changes merged into it until required reviews are approvedCan't be edited or have files uploaded to it from the webAnd Since October 2016, you can dismiss a reviewHowever, this requirement can sometimes block your team’s progress without good reason.If someone leaves a review that requests changes and then goes on vacation or runs into computer problems, your pull request could be blocked for days, even after you’ve addressed the reviewer’s concerns.This will unblock your pull request, freeing you up to merge it! 这篇关于如何在GitHub中禁用拉取请求?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持! 上岸,阿里云! 07-31 11:44