From 6698bbf68fc5cd50ba1dd05d0dc5eca13afa0ac5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gina=20H=C3=A4u=C3=9Fge?= Date: Wed, 13 Jan 2021 15:46:12 +0100 Subject: [PATCH] =?UTF-8?q?=F0=9F=91=B7=20Add=20PR=20automation=20workflow?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Will help us label PRs based on their contents, and then that info can be used to make the whole branch validation a bit more intelligent. For reasons of consistency, also rename issue labeler to issue automation. --- .github/labeler.yml | 25 +++++++++++++++++++ ...issue_labeler.yml => issue_automation.yml} | 4 +-- .github/workflows/pr_automation.yml | 11 ++++++++ 3 files changed, 38 insertions(+), 2 deletions(-) create mode 100644 .github/labeler.yml rename .github/workflows/{issue_labeler.yml => issue_automation.yml} (97%) create mode 100644 .github/workflows/pr_automation.yml diff --git a/.github/labeler.yml b/.github/labeler.yml new file mode 100644 index 000000000..ed3f1c77a --- /dev/null +++ b/.github/labeler.yml @@ -0,0 +1,25 @@ +docs: + - "docs/*" + - "docs/**/*" + - "README.md" + +meta: + - "CODE_OF_CONDUCT.md" + - "CONTRIBUTING.md" + - "SECURITY.md" + - ".github/CODEOWNERS" + - ".github/FUNDING.yml" + - ".github/ISSUE_TEMPLATE/*" + - ".github/PULL_REQUEST_TEMPLATE.md" + +ci/cd: + - ".github/fixtures/**/*" + - ".github/workflows/*" + - ".github/labeler.yml" + +docker: + - ".github/workflows/trigger_docker.yml" + +tests: + - "tests/*" + - "tests/**/*" diff --git a/.github/workflows/issue_labeler.yml b/.github/workflows/issue_automation.yml similarity index 97% rename from .github/workflows/issue_labeler.yml rename to .github/workflows/issue_automation.yml index 5b6e026e7..f3024d73f 100644 --- a/.github/workflows/issue_labeler.yml +++ b/.github/workflows/issue_automation.yml @@ -1,10 +1,10 @@ -name: "Issue Labeler" +name: "Issue Automation" on: issues: types: [opened, edited, closed, reopened] jobs: - label-opened-and-edited: + label: runs-on: ubuntu-latest steps: - uses: actions/github-script@v2 diff --git a/.github/workflows/pr_automation.yml b/.github/workflows/pr_automation.yml new file mode 100644 index 000000000..ee0b8832f --- /dev/null +++ b/.github/workflows/pr_automation.yml @@ -0,0 +1,11 @@ +name: "Pull Request Automation" +on: + - pull_request_target + +jobs: + label: + runs-on: ubuntu-latest + steps: + - uses: actions/labeler@v3 + with: + repo-token: "${{ secrets.GITHUB_TOKEN }}"