批准需要审查的拉取请求
如果您的仓库需要审查,拉取请求必须由对仓库具有写入或管理员权限的人员进行特定数量的批准审查,然后才可合并。
有关必需审查的更多信息,请参阅“关于拉取请求的必需审查”。
您可以评论拉取请求、批准更改或在批准前申请改进。 更多信息请参阅“关于拉取请求的必需审查”和“审查拉取请求中提议的更改”。
使用搜索限定符 review-requested:[USERNAME]
或 team-review-requested:[TEAMNAME]
可查找请求您或您所属团队审查的拉取请求。更多信息请参阅“搜索议题和拉取请求”。
提示:如果您批准的拉取请求发生了重要更改,您可以忽略审查。 拉取请求在合并前需要新的审查。 更多信息请参阅“忽略拉取请求审查”。
-
在仓库名称下,单击 Pull requests(拉取请求)。
-
在拉取请求列表中,单击要审查的拉取请求。
-
在拉取请求上,单击 Files changed(文件已更改)。
-
审查拉取请求中的更改,并且选择评论特定行。
-
在已更改代码的上方,单击 Review changes(审查更改)。
-
键入评论以总结您对提议更改的反馈。
-
选择 Approve(批准)以评估合并拉取请求中提议的更改。
-
单击 Submit review(提交审查)。
提示:
- If required reviews are enabled and a collaborator with write, admin, or owner access to the repository submits a review requesting changes, the pull request cannot be merged until the same collaborator submits another review approving the changes in the pull request.
- Repository owners and administrators can merge a pull request even if it hasn't received an approving review, or if a reviewer who requested changes has left the organization or is unavailable.
- If both required reviews and stale review dismissal are enabled and a code-modifying commit is pushed to the branch of an approved pull request, the approval is dismissed. The pull request must be reviewed and approved again before it can be merged.
- When several open pull requests each have a head branch pointing to the same commit, you won’t be able to merge them if one or both have a pending or rejected review.
延伸阅读
- "关于拉取请求的必要审查"
- "审查拉取请求中提议的更改"
- "评论拉取请求"