From 1b82ac932e8f9129e53336951c111a8d67b5c588 Mon Sep 17 00:00:00 2001 From: Jan Klattenhoff Date: Mon, 26 Aug 2024 14:32:21 +0200 Subject: [PATCH] feat(ci): add release workflow and config files --- .gitea/workflows/release.yaml | 27 +++++++++++++++++++++++++++ release.config.cjs | 13 +++++++++++++ 2 files changed, 40 insertions(+) create mode 100644 .gitea/workflows/release.yaml create mode 100644 release.config.cjs diff --git a/.gitea/workflows/release.yaml b/.gitea/workflows/release.yaml new file mode 100644 index 0000000..b1c31c0 --- /dev/null +++ b/.gitea/workflows/release.yaml @@ -0,0 +1,27 @@ +name: Release +on: + push: + +env: + GITEA_TOKEN: ${{ secrets.GITEA_TOKEN }} + +permissions: + contents: read # for checkout + +jobs: + release: + name: Release + runs-on: ubuntu-latest + permissions: + contents: write # to be able to publish a GitHub release + issues: write # to be able to comment on released issues + pull-requests: write # to be able to comment on released pull requests + id-token: write # to enable use of OIDC for npm provenance + steps: + - name: Create Release + uses: https://git.kjan.de/actions/semantic-release@main + with: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + GITEA_TOKEN: ${{ secrets.GITEA_TOKEN }} + + diff --git a/release.config.cjs b/release.config.cjs new file mode 100644 index 0000000..12f035c --- /dev/null +++ b/release.config.cjs @@ -0,0 +1,13 @@ +module.exports = { + + branches: ['main'], + plugins: [ + '@semantic-release/commit-analyzer', + '@semantic-release/release-notes-generator', + '@semantic-release/changelog', + ["@saithodev/semantic-release-gitea", { + "giteaUrl": "https://git.kjan.de" + }], + ], +}; + -- 2.45.2