Harden release upload scripts
ci / test (push) Has been cancelled
ci / fuzz-smoke (push) Has been cancelled
ci / windows-client (push) Has been cancelled
ci / package-release (linux-x86_64, ubuntu-latest) (push) Has been cancelled
ci / package-release (macos-aarch64, macos-14) (push) Has been cancelled
ci / package-release (macos-x86_64, macos-13) (push) Has been cancelled
ci / package-release (windows-x86_64, windows-latest) (push) Has been cancelled
ci / remote-bench (push) Has been cancelled

This commit is contained in:
DuProcess
2026-06-22 01:42:17 -04:00
parent 149ea07edf
commit 44717e4956
2 changed files with 8 additions and 1 deletions
+1 -1
View File
@@ -43,7 +43,7 @@ Environment alternatives:
DOSH_BINARY_URL URL DOSH_BINARY_URL URL
Exact release tarball URL to install Exact release tarball URL to install
DOSH_BINARY_BASE URL DOSH_BINARY_BASE URL
Release download base; defaults to REPO/releases/latest/download Release download base; otherwise derived from the latest tag
DOSH_BINARY_NAME NAME DOSH_BINARY_NAME NAME
Release tarball name; defaults to dosh-OS-ARCH.tar.gz Release tarball name; defaults to dosh-OS-ARCH.tar.gz
DOSH_BINARY_VERSION TAG DOSH_BINARY_VERSION TAG
+7
View File
@@ -102,6 +102,7 @@ delete_existing_asset() {
done done
} }
uploaded=0
for artifact in "$@"; do for artifact in "$@"; do
if [ ! -f "$artifact" ]; then if [ ! -f "$artifact" ]; then
continue continue
@@ -114,4 +115,10 @@ for artifact in "$@"; do
-X POST \ -X POST \
-F "attachment=@$artifact" \ -F "attachment=@$artifact" \
"$api/releases/$release_id/assets?name=$name" >/dev/null "$api/releases/$release_id/assets?name=$name" >/dev/null
uploaded=$((uploaded + 1))
done done
if [ "$uploaded" -eq 0 ]; then
echo "no release artifacts uploaded" >&2
exit 1
fi