Add GitHub action to label pull requests

This commit is contained in:
Bruno Alla 2020-04-17 19:18:56 +01:00
parent d02b88f681
commit 7a435b3d4a
2 changed files with 31 additions and 0 deletions

11
.github/labeler.yml vendored Normal file
View File

@ -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

20
.github/workflows/label.yml vendored Normal file
View File

@ -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 }}"