From a8256100f9061081746274b06facef6e5b7f2bb4 Mon Sep 17 00:00:00 2001 From: Marty Oehme Date: Fri, 25 Aug 2023 20:47:14 +0200 Subject: [PATCH] =?UTF-8?q?=F0=9F=90=9B=20Fix=20release=20automation=20nam?= =?UTF-8?q?ing=20scheme?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Names for tags in this repo start with a `v` (e.g. `v0.3.1`) but the release automation did not know about this and would create duplicate tags without the preceding letter. --- .woodpecker.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.woodpecker.yml b/.woodpecker.yml index 5eac51d..ff38c43 100644 --- a/.woodpecker.yml +++ b/.woodpecker.yml @@ -73,7 +73,7 @@ pipeline: - apk add file jq curl - BM_VERSION=$(cat NEWEST_VERSION.txt) - BM_CHANGED=$(sed -e 's|#||g' -e 's|^.*$|\0
|' NEWEST_CHANGES.txt) # display newlines workaround - - echo "{\"tag_name\":\"$BM_VERSION\",\"target_commitish\":\"main\",\"name\":\"$BM_VERSION\",\"body\":\"$BM_CHANGED\",\"draft\":false,\"prerelease\":false,\"generate_release_notes\":false}" > data.json + - echo "{\"tag_name\":\"v${BM_VERSION}\",\"target_commitish\":\"main\",\"name\":\"v${BM_VERSION}\",\"body\":\"$BM_CHANGED\",\"draft\":false,\"prerelease\":false,\"generate_release_notes\":false}" > data.json - "response=$(curl -X POST -H \"Accept:\\ application/vnd.github+json\" -H \"Authorization:\\ Bearer $GITHUB_RELEASE_TOKEN\" https://api.github.com/repos/$GITHUB_REPO/releases -d \"@data.json\")" - "uploadurl=$(echo $response | jq -r '.upload_url' | cut -d'{' -f1)" - "[ $uploadurl = null ] && { echo $response; exit 1; }"