diff --git a/.github/release-drafter.yml b/.github/release-drafter.yml index a4dce4c2..64e1f4e7 100644 --- a/.github/release-drafter.yml +++ b/.github/release-drafter.yml @@ -1,3 +1,40 @@ +categories: + - title: "🚀 Features" + labels: + - "feature" + - "enhancement" + - title: "🐛 Bug Fixes" + labels: + - "fix" + - "bugfix" + - "bug" + - title: "🧰 Maintenance" + labels: + - "chore" + - title: "⬆️ Dependencies" + labels: + - "dependencies" +change-title-escapes: '\<*_&`' +commitish: main + +autolabeler: + - label: "chore" + files: + - "*.md" + branch: + - '/docs{0,1}\/.+/' + - label: "bugfix" + branch: + - '/bugfix\/.+/' + title: + - "/fix/i" + - label: "feature" + branch: + - '/feature\/.+/' + - label: "dependencies" + branch: + - '/dependabot\/.+/' + template: | ## What's Changed diff --git a/.github/workflows/autolabeler.yml b/.github/workflows/autolabeler.yml new file mode 100644 index 00000000..e859b30a --- /dev/null +++ b/.github/workflows/autolabeler.yml @@ -0,0 +1,16 @@ +# yamllint disable-line rule:truthy +on: + pull_request: + types: [opened, reopened, synchronize] + +permissions: + contents: read + +jobs: + auto_label: + permissions: + pull-requests: write + runs-on: ubuntu-latest + steps: + # runs autolabeler + - uses: release-drafter/release-drafter/autolabeler@v7 diff --git a/.github/workflows/release-drafter.yml b/.github/workflows/release-drafter.yml index 1d061a42..3718e9bb 100644 --- a/.github/workflows/release-drafter.yml +++ b/.github/workflows/release-drafter.yml @@ -21,10 +21,12 @@ jobs: contents: write # write permission is required for autolabeler # otherwise, read permission is required at least - pull-requests: write + pull-requests: read runs-on: ubuntu-latest steps: # Drafts your next Release notes as Pull Requests are merged into "main" - - uses: release-drafter/release-drafter@v6 + - uses: release-drafter/release-drafter@v7 + with: + config-name: release-drafter.yml # the default, loads '.github/release-drafter.yml' env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 38418e4e..a223c10c 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -33,7 +33,7 @@ repos: hooks: - id: codespell args: - - --ignore-words-list=astroid,addin + - --ignore-words-list=astroid,addin,commitish - --quiet-level=2 - repo: https://github.com/adrienverge/yamllint.git rev: v1.38.0