百科.dev
全部条目在线工具AI 编程趋势榜开源项目技术资讯提交条目
登录
< 返回工具列表
A

auto-assign-action

> 开发工具
开源

在打开 Pull Request 后,添加审阅者到 Pull Request 的操作。

399 stars0 点赞1 次浏览
访问官网GitHub

工具介绍

在打开 Pull Request 后,添加审阅者到 Pull Request 的操作。

Auto Assign Action

An action which adds reviewers to the pull request when the pull request is opened.

:arrow_forward: Usage

Create a workflow (e.g. .github/workflows/action.yml For more detail, refer to Configuring a workflow) for running the auto-assign action.

yaml
name: 'Auto Assign'
on:
  pull_request:
    types: [opened, ready_for_review]

jobs:
  add-reviews:
    runs-on: ubuntu-latest
    steps:
      - uses: kentaro-m/[email protected]
        with:
          configuration-path: '.github/some_name_for_configs.yml' # Only needed if you use something other than .github/auto_assign.yml

Change event that triggers a workflow to the pull_request_target if you want to enable the auto-assign action when opening pull requests from fork repositories or bots like Dependabot.

Using dangerous misuse of the pull_request_target event can be a security risk, so make sure you understand pros and cons before using it.

See below for details:

  • Events that trigger workflows / Pull request target - GitHub Docs
  • Events that trigger workflows / Pull request events for forked repositories - GitHub Docs
diff
name: 'Auto Assign'
 on:
-  pull_request:
+  pull_request_target:
     types: [opened, ready_for_review]

 jobs:

Create a separate configuration file for the auto-assign action (e.g. .github/auto_assign.yml).

Single Reviewers List

Add reviewers/assignees to the pull request based on single reviewers list.

…

Multiple Reviewers List

Add reviewers/assignees to the pull request based on multiple reviewers list.

If you and peers work at the separate office or they work at the separate team by roles like frontend and backend, you might be good to use adding reviewers from each group.

…

Assign Author as Assignee

Add the PR creator as the assignee of the pull request.

yaml
# Set addAssignees to 'author' to set the PR creator as the assignee.
addAssignees: author

Filter by label

The action will only run if the PR meets the specified filters

yaml
filterLabels:
  # Run
  include:
    - my_label
    - another_label
  # Not run
  exclude:
    - wip

Filter draft PRs

The action will only run for non-draft PRs. If you want to run for all PRs, you need to enable it to run on drafts.

yaml
runOnDraft: true

:memo: Licence

MIT

Issues· 47 开放

查看全部 Issues在 GitHub 打开

暂无开放 Issues,或尚未同步最近议题。

> 标签

TypeScriptgithub-actionsmy-portfoliopull-requestworkflow

暂无评论,来聊聊你的看法吧

> 工具信息

发布日期2026年8月1日
最后更新2026年9月17日
分类开发工具
定价开源

> 相关工具

V
VS Code
流行的开源代码编辑器
G
Git
分布式版本控制系统
V
Vite
下一代前端构建工具