From 7a435b3d4a14296f239bd9c4df4ffbedbcc7edc3 Mon Sep 17 00:00:00 2001 From: Bruno Alla Date: Fri, 17 Apr 2020 19:18:56 +0100 Subject: [PATCH] Add GitHub action to label pull requests --- .github/labeler.yml | 11 +++++++++++ .github/workflows/label.yml | 20 ++++++++++++++++++++ 2 files changed, 31 insertions(+) create mode 100644 .github/labeler.yml create mode 100644 .github/workflows/label.yml diff --git a/.github/labeler.yml b/.github/labeler.yml new file mode 100644 index 000000000..bad7cac06 --- /dev/null +++ b/.github/labeler.yml @@ -0,0 +1,11 @@ +# Add 'docs' to any changes within 'docs' folder or any subfolders +docs: + - README.rst + - docs/**/* + - {{cookiecutter.project_slug}}/docs/**/* + +# Flag PR related to docker +docker: + - {{cookiecutter.project_slug}}/compose/**/* + - {{cookiecutter.project_slug}}/local.yml + - {{cookiecutter.project_slug}}/production.yml diff --git a/.github/workflows/label.yml b/.github/workflows/label.yml new file mode 100644 index 000000000..3df0ec0c0 --- /dev/null +++ b/.github/workflows/label.yml @@ -0,0 +1,20 @@ +# This workflow will triage pull requests and apply a label based on the +# paths that are modified in the pull request. +# +# To use this workflow, you will need to set up a .github/labeler.yml +# file with configuration. For more information, see: +# https://github.com/actions/labeler/blob/master/README.md + + +name: Labeler +on: [pull_request] + +jobs: + label: + + runs-on: ubuntu-latest + + steps: + - uses: actions/labeler@v2 + with: + repo-token: "${{ secrets.GITHUB_TOKEN }}"