ci: respect GITHUB_REPOSITORY for bundle name + tolerate per-asset upload failures
release / release (push) Successful in 2s
release / release (push) Successful in 2s
- build_zip.sh: derive <repo>-all.zip name from $GITHUB_REPOSITORY when set (in Gitea Actions the toplevel basename is the worker dir, not the repo). Falls back to git toplevel for local invocations. - release.yml: skip assets above MAX_BYTES (200 MiB Gitea ceiling) and continue on individual upload failures. Job only fails if ZERO assets uploaded. Previously one oversized zip would block the whole release.
This commit is contained in:
+12
-1
@@ -6,12 +6,23 @@
|
||||
# - Always archives HEAD, so the working tree state is irrelevant.
|
||||
# - If more than one addon folder is present, also emits <repo>-all.zip
|
||||
# with every addon folder side-by-side at the zip root.
|
||||
# - When run inside Gitea Actions the working tree lives under a
|
||||
# per-job dir like /var/lib/act_runner/work/.../hostexecutor, so the
|
||||
# repo name comes from $GITHUB_REPOSITORY (set by the runner) and
|
||||
# only falls back to the toplevel basename for local invocations.
|
||||
set -euo pipefail
|
||||
|
||||
root=$(git rev-parse --show-toplevel)
|
||||
cd "$root"
|
||||
|
||||
repo_name=$(basename "$root")
|
||||
# Gitea Actions sets GITHUB_REPOSITORY=owner/repo. The basename of
|
||||
# `git rev-parse --show-toplevel` inside the runner is the worker dir
|
||||
# (e.g. `hostexecutor`), which would name the bundle wrong.
|
||||
if [ -n "${GITHUB_REPOSITORY:-}" ]; then
|
||||
repo_name="${GITHUB_REPOSITORY##*/}"
|
||||
else
|
||||
repo_name=$(basename "$root")
|
||||
fi
|
||||
dist="$root/dist"
|
||||
|
||||
# Find Foo/Foo.toc pairs at depth 1; ignore libs nested deeper.
|
||||
|
||||
Reference in New Issue
Block a user