From 9347d67b4e343e9cee3c8bb855a03003057f911c Mon Sep 17 00:00:00 2001 From: Akihiro Nitta Date: Tue, 12 Jul 2022 06:46:36 +0900 Subject: [PATCH] CI: Add PR labeler (#13475) * Add pr labeler * Triger on docs change * Make mutually exclusive * Add requirements * files Co-authored-by: Rohit Gupta Co-authored-by: Jirka Borovec Co-authored-by: Rohit Gupta --- .github/labeler.yml | 7 +++++++ .github/workflows/labeler.yml | 15 +++++++++++++++ 2 files changed, 22 insertions(+) create mode 100644 .github/labeler.yml create mode 100644 .github/workflows/labeler.yml diff --git a/.github/labeler.yml b/.github/labeler.yml new file mode 100644 index 0000000000..bba4ddec5d --- /dev/null +++ b/.github/labeler.yml @@ -0,0 +1,7 @@ +app: +- any: ['src/lightning*/**/*', 'tests/tests_app*/**/*', 'docs/source-app/**/*', 'requirements/app/*'] + all: ['!src/pytorch_lightning/**/*', '!tests/tests_pytorch/**/*', '!docs/source-pytorch/**/*', '!requirements/pytorch/*'] + +pl: +- any: ['src/pytorch_lightning/**/*', 'tests/tests_pytorch/**/*', 'docs/source-pytorch/**/*', 'requirements/pytorch/*'] + all: ['!src/lightning*/**/*', '!tests/tests_app*/**/*', '!docs/source-app/**/*', '!requirements/app/*'] diff --git a/.github/workflows/labeler.yml b/.github/workflows/labeler.yml new file mode 100644 index 0000000000..fe060c10cb --- /dev/null +++ b/.github/workflows/labeler.yml @@ -0,0 +1,15 @@ +name: Label Pull Requests +on: +- pull_request_target + +jobs: + triage: + permissions: + contents: read + pull-requests: write + runs-on: ubuntu-latest + steps: + - uses: actions/labeler@v4 + with: + repo-token: "${{ secrets.GITHUB_TOKEN }}" + sync-labels: true