diff --git a/.github/auto-label.json b/.github/auto-label.json new file mode 100644 index 0000000000..7cdb9270a4 --- /dev/null +++ b/.github/auto-label.json @@ -0,0 +1,6 @@ +{ + "rules": { + "frontend": ["webapp/"], + "backend": ["*.go"] + } +} diff --git a/.github/workflows/auto-label.yml b/.github/workflows/auto-label.yml new file mode 100644 index 0000000000..0a948c2e3f --- /dev/null +++ b/.github/workflows/auto-label.yml @@ -0,0 +1,17 @@ +name: Auto Label +on: + pull_request_target: + types: [opened, synchronize] + +jobs: + auto-label: + name: Auto Label + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + with: + ref: ${{github.event.pull_request.head.ref}} + repository: ${{github.event.pull_request.head.repo.full_name}} + - uses: banyan/auto-label@1.2 + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} diff --git a/.github/workflows/auto-request-review.yml b/.github/workflows/auto-request-review.yml index 9553eb68ac..181be80c40 100644 --- a/.github/workflows/auto-request-review.yml +++ b/.github/workflows/auto-request-review.yml @@ -2,7 +2,7 @@ name: Auto Request Review on: - pull_request: + pull_request_target: types: [opened, ready_for_review, reopened] jobs: @@ -13,5 +13,5 @@ jobs: - name: Request review based on files changes and/or groups the author belongs to uses: necojackarc/auto-request-review@v0.4.0 with: - token: ${{ secrets.AUTO_REVIEW_GITHUB_TOKEN }} + token: ${{ secrets.GITHUB_TOKEN }} config: .github/reviewers.yml # Config file location override