From 3b4bd5836f7e74f015dfabb9fe2a7730a401e7ea Mon Sep 17 00:00:00 2001 From: Ales Zelenik Date: Mon, 5 Aug 2024 14:26:36 +0200 Subject: [PATCH] fix: semrelease hooks (#25) --- .github/workflows/semantic-release.yaml | 2 +- .releaserc | 18 ++++++++++++++---- 2 files changed, 15 insertions(+), 5 deletions(-) diff --git a/.github/workflows/semantic-release.yaml b/.github/workflows/semantic-release.yaml index 00ed85d..0b8676f 100644 --- a/.github/workflows/semantic-release.yaml +++ b/.github/workflows/semantic-release.yaml @@ -20,4 +20,4 @@ jobs: with: github-token: ${{ secrets.PAT }} allow-initial-development-versions: true - hooks: exec + hooks: exec,git diff --git a/.releaserc b/.releaserc index 69745ea..4bdacf1 100644 --- a/.releaserc +++ b/.releaserc @@ -1,7 +1,17 @@ { "plugins": [ - ["@semantic-release/exec", { - "publishCmd": "sed -i 's/\(newTag:\).*/\1 ${nextRelease.version}/' deploy/kustomize/overlays/*/kustomization.yaml" - }], + [ + "@semantic-release/exec", + { + "publishCmd": "echo \"Running sed with exec plugin\" && sed -i 's/\\(newTag:\\).*/\\1 ${nextRelease.version}/' deploy/kustomize/overlays/*/kustomization.yaml" + }, + "@semantic-release/git", + { + "assets": [ + "deploy/kustomize/overlays/*/kustomization.yaml" + ], + "message": "chore(release): ${nextRelease.version} [skip ci]\n\n${nextRelease.notes}" + } + ] ] -} +} \ No newline at end of file