Skip to content

Commit dec15d8

Browse files
committed
post to prerelease first when auto updating
1 parent 6066c88 commit dec15d8

1 file changed

Lines changed: 8 additions & 2 deletions

File tree

game_clean/tag.sh

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,13 @@ source ./shared.sh
1111
git fetch --tags origin
1212

1313
if git rev-parse ${VERSION} -- > /dev/null 2>&1; then
14-
echo "::warning Tag ${VERSION} already exists. Not creating a release."
15-
(gh release upload ${VERSION} "../game-${PLATFORM}.zip" || true)
14+
#echo "::warning Tag ${VERSION} already exists. Not creating a release."
15+
IS_PRERELEASE=$(gh release view ${VERSION} --json "isPrerelease" --template "{{.isPrerelease}}")
16+
if [ "${IS_PRERELEASE}" == "true" ]; then
17+
gh release upload --clobber ${VERSION} "../game-${PLATFORM}.zip" || true
18+
else
19+
gh release upload ${VERSION} "../game-${PLATFORM}.zip" || true
20+
fi
1621
else
1722
printf "Release ${VERSION}\n\n[Download](https://teamcomtress.com/)\n[Patch Notes](https://teamcomtress.com/feed/#patches)" > "notes.txt"
1823
git tag ${VERSION}
@@ -22,6 +27,7 @@ else
2227
"../game-${PLATFORM}.zip" \
2328
--title "${VERSION}" \
2429
-F "notes.txt" \
30+
--prerelease \
2531
--verify-tag \
2632
--fail-on-no-commits
2733
rm notes.txt

0 commit comments

Comments
 (0)