chore: automatically label new pull requests (#400)

This commit is contained in:
Tommy Nguyen 2021-07-14 18:42:55 +02:00 коммит произвёл GitHub
Родитель e5c57953b9
Коммит ff4f41509f
Не найден ключ, соответствующий данной подписи
Идентификатор ключа GPG: 4AEE18F83AFDEB23
2 изменённых файлов: 48 добавлений и 25 удалений

12
.github/labeler.yml поставляемый Normal file
Просмотреть файл

@ -0,0 +1,12 @@
'feature: cli':
- packages/cli/**/*
- packages/config/**/*
'feature: dep-check':
- packages/dep-check/**/*
'feature: metro':
- packages/babel-plugin-import-path-remapper/**/*
- packages/babel-preset-metro-react-native/**/*
- packages/metro-*/**/*
- packages/typescript-service/**/*
'feature: third party notices':
- packages/third-party-notices/**/*

61
.github/workflows/pr.yml поставляемый
Просмотреть файл

@ -1,6 +1,34 @@
name: CI
on: pull_request
jobs:
review:
name: "Review"
runs-on: ubuntu-latest
steps:
- name: Set up Node 14
uses: actions/setup-node@v2.2.0
with:
node-version: 14
- name: Checkout
uses: actions/checkout@v2.3.4
- name: Deduplicate packages
run: |
npx yarn-deduplicate --list --fail
- name: Cache /.yarn-offline-mirror
uses: actions/cache@v2.1.6
with:
path: .yarn-offline-mirror
key: ${{ hashFiles('yarn.lock') }}
- name: Install package dependencies
run: yarn ci
- name: Check for change files
run: yarn run check
- name: Format
run: yarn format
- name: Align dependencies
run: yarn rnx-dep-check --write
- name: Report changes
run: git diff | GITHUB_TOKEN=${{ secrets.GITHUB_TOKEN }} yarn suggestion-bot
build:
name: "Build"
strategy:
@ -38,31 +66,14 @@ jobs:
yarn bundle+esbuild
shell: bash
working-directory: packages/test-app
review:
name: "Review"
label:
name: "Label"
runs-on: ubuntu-latest
permissions:
contents: read
pull-requests: write
steps:
- name: Set up Node 14
uses: actions/setup-node@v2.2.0
- uses: actions/labeler@v2
with:
node-version: 14
- name: Checkout
uses: actions/checkout@v2.3.4
- name: Deduplicate packages
run: |
npx yarn-deduplicate --list --fail
- name: Cache /.yarn-offline-mirror
uses: actions/cache@v2.1.6
with:
path: .yarn-offline-mirror
key: ${{ hashFiles('yarn.lock') }}
- name: Install package dependencies
run: yarn ci
- name: Check for change files
run: yarn run check
- name: Format
run: yarn format
- name: Align dependencies
run: yarn rnx-dep-check --write
- name: Report changes
run: git diff | GITHUB_TOKEN=${{ secrets.GITHUB_TOKEN }} yarn suggestion-bot
repo-token: "${{ secrets.GITHUB_TOKEN }}"
sync-labels: true