mirror of
https://github.com/outbackdingo/firezone.git
synced 2026-01-27 10:18:54 +00:00
- Attaching the standalone client needs to happen on `main` runs, like the other clients - GitHub can't seem to find the release. I suspect the `GITHUB_REPOSITORY` var is unneeded.
21 lines
493 B
Bash
Executable File
21 lines
493 B
Bash
Executable File
#!/usr/bin/env bash
|
|
|
|
# Uploads built packages to a GitHub release
|
|
|
|
set -euo pipefail
|
|
|
|
# Only clobber existing release assets if the release is a draft
|
|
is_draft=$(gh release view "$RELEASE_NAME" --json isDraft --jq '.isDraft' | tr -d '\n')
|
|
if [[ "$is_draft" == "true" ]]; then
|
|
clobber="--clobber"
|
|
else
|
|
clobber=""
|
|
fi
|
|
|
|
sha256sum "$ARTIFACT_PATH" >"$ARTIFACT_PATH.sha256sum.txt"
|
|
|
|
gh release upload "$RELEASE_NAME" \
|
|
"$ARTIFACT_PATH" \
|
|
"$ARTIFACT_PATH.sha256sum.txt" \
|
|
$clobber
|