Skip to content

Commit

Permalink
[BREAKING CHANGE] Change how to specify teams (#45)
Browse files Browse the repository at this point in the history
* Change the way to specify GitHub teams

* Bump version to 0.7.0
  • Loading branch information
necojackarc authored Apr 20, 2021
1 parent 12d9403 commit e08cdff
Show file tree
Hide file tree
Showing 7 changed files with 5,308 additions and 2,269 deletions.
10 changes: 6 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -120,12 +120,14 @@ reviewers:
defaults:
- repository-owners # group
- octocat # username
- team:default-reviewers # GitHub team
# Reviewer groups each of which has a list of GitHub usernames
groups:
repository-owners:
- me # username
- you # username
- team:owners # GitHub team
core-contributors:
- good-boy # username
- good-girl # username
Expand All @@ -138,6 +140,7 @@ reviewers:
per_author:
engineers:
- engineers # group
- team:engineering-managers # GitHub team
lead_designer:
- js-lovers # group
- desinger_a # username
Expand All @@ -152,6 +155,7 @@ files:
# You can assign groups defined above as well as GitHub usernames.
'**':
- repository-owners # group
- team:external-reviewers # GitHub team
'**/*.js':
- core-contributors # group
- js-lovers # group
Expand All @@ -175,8 +179,6 @@ options:

The default configuration file location is `.github/auto_request_review.yml` but you can override it in your workflow configuration file.

To specify reviewers, you can use GitHub teams as well as GitHub usernames, however, you need to configure your personal access token (see below).

### Workflow configuration
Create a workflow file in `.github/workflows` (e.g. `.github/workflows/auto_request_review.yml`):

Expand All @@ -193,7 +195,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Request review based on files changes and/or groups the author belongs to
uses: necojackarc/auto-request-review@v0.6.0
uses: necojackarc/auto-request-review@v0.7.0
with:
token: ${{ secrets.GITHUB_TOKEN }}
config: .github/reviewers.yml # Config file location override
Expand All @@ -212,7 +214,7 @@ Let's say you have a `@your-awesome-org/happy-team` team and make a new secret `
```yaml
files:
'**':
- happy-team # GitHub team
- team:happy-team # GitHub team
```

```yaml
Expand Down
Loading

0 comments on commit e08cdff

Please sign in to comment.