From ce4f8eaeec1f93752149be1e673b499d3d024f3a Mon Sep 17 00:00:00 2001 From: Igor Miler Date: Wed, 21 Feb 2024 10:47:10 +0100 Subject: [PATCH] adding required files for new ruleset --- .github/labeler.yml | 19 +++++++++++++ .github/pull_request_template.md | 33 ++++++++++++++++++++++ .github/reviewers.yml | 4 +++ .github/workflows/labelling.yaml | 47 ++++++++++++++++++++++++++++++++ 4 files changed, 103 insertions(+) create mode 100644 .github/labeler.yml create mode 100644 .github/pull_request_template.md create mode 100644 .github/reviewers.yml create mode 100644 .github/workflows/labelling.yaml diff --git a/.github/labeler.yml b/.github/labeler.yml new file mode 100644 index 0000000..1b3251f --- /dev/null +++ b/.github/labeler.yml @@ -0,0 +1,19 @@ +Feature: + - head-branch: ['^feature', 'feature'] +Hotfix: + - head-branch: ['^hotfix', 'hotfix'] +Documentation: +- changed-files: + - any-glob-to-any-file: '**/*.md' +CICD: +- changed-files: + - any-glob-to-any-file: '.github/**' + +typescript: +- changed-files: + - any-glob-to-any-file: '**/*.ts' +css: +- changed-files: + - any-glob-to-any-file: '**/*.css' + + diff --git a/.github/pull_request_template.md b/.github/pull_request_template.md new file mode 100644 index 0000000..ccf23da --- /dev/null +++ b/.github/pull_request_template.md @@ -0,0 +1,33 @@ +# Description + +Please include a summary of the changes and the related issue. Please also include relevant motivation and context. List any dependencies that are required for this change. + +Fixes # (issue) + +## Type of change + +Please delete options that are not relevant. + +- [ ] Bug fix (non-breaking change which fixes an issue) +- [ ] New feature (non-breaking change which adds functionality) +- [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected) +- [ ] This change requires a documentation update + +# How Has This Been Tested? + +Please describe the tests that you ran to verify your changes. Provide instructions so we can reproduce. Please also list any relevant details for your test configuration + +- [ ] Test A +- [ ] Test B + + +# Checklist: + +- [ ] My code follows the style guidelines of this project +- [ ] I have performed a self-review of my code +- [ ] I have commented my code, particularly in hard-to-understand areas +- [ ] I have made corresponding changes to the documentation +- [ ] My changes generate no new warnings +- [ ] I have added tests or screenshots that prove my fix is effective or that my feature works +- [ ] Any dependent changes have been merged and published in downstream modules + diff --git a/.github/reviewers.yml b/.github/reviewers.yml new file mode 100644 index 0000000..0e371d2 --- /dev/null +++ b/.github/reviewers.yml @@ -0,0 +1,4 @@ +reviewers: + defaults: + - repository-owners + - bbrauneck \ No newline at end of file diff --git a/.github/workflows/labelling.yaml b/.github/workflows/labelling.yaml new file mode 100644 index 0000000..205e046 --- /dev/null +++ b/.github/workflows/labelling.yaml @@ -0,0 +1,47 @@ +name: label PRs +on: + pull_request: + branches: [dev, master] +jobs: + size-label: + needs: pr-reviewer + permissions: + contents: read + pull-requests: write + runs-on: ubuntu-latest + steps: + - name: size-label + uses: "pascalgn/size-label-action@v0.5.0" + env: + GITHUB_TOKEN: "${{ secrets.GITHUB_TOKEN }}" + with: + sizes: > + { + "0": "XS", + "20": "S", + "50": "M", + "200": "L", + "800": "XL", + "2000": "XXL" + } + - name: general-labels + uses: actions/labeler@v5 + with: + sync-labels: true + pr-reviewer: + permissions: + contents: read + pull-requests: write + runs-on: ubuntu-latest + steps: + - name: Checkout + uses: actions/checkout@v3 + with: + token: ${{ secrets.PAT || secrets.GITHUB_TOKEN }} + fetch-depth: 0 + - name: Request review and assign + uses: necojackarc/auto-request-review@v0.13.0 + with: + token: ${{ secrets.GITHUB_TOKEN }} + config: .github/reviewers.yml + use_local: true