burrow/bazel/apple/runner.sh
Conrad Kramer 002bd382e9
Some checks failed
Cache: Publish Nix / Publish Nix Cache (push) Waiting to run
Build Rust / Cargo Test (push) Successful in 4m14s
Build Site / Next.js Build (push) Failing after 6s
Infra: OpenTofu / OpenTofu (grafana) (push) Successful in 5s
Lint Governance / BEP Metadata (push) Successful in 0s
Build: Android / Android Rust Core Stub (push) Failing after 23s
Wire Forge-native release infrastructure
2026-06-07 05:51:12 -07:00

42 lines
875 B
Bash
Executable file

#!/usr/bin/env bash
set -euo pipefail
command="${1:-}"
resolve_repo_root() {
if [[ -n "${BUILD_WORKSPACE_DIRECTORY:-}" && -f "${BUILD_WORKSPACE_DIRECTORY}/MODULE.bazel" ]]; then
printf '%s\n' "$BUILD_WORKSPACE_DIRECTORY"
return 0
fi
local dir="$PWD"
while [[ "$dir" != "/" ]]; do
if [[ -f "$dir/MODULE.bazel" && -d "$dir/Apple" ]]; then
printf '%s\n' "$dir"
return 0
fi
dir="$(dirname "$dir")"
done
echo "unable to resolve Burrow repository root" >&2
return 1
}
repo_root="$(resolve_repo_root)"
cd "$repo_root"
case "$command" in
release-ios)
Scripts/ci/package-apple-artifacts.sh ios
;;
release-macos)
Scripts/ci/package-apple-artifacts.sh macos
;;
release-all)
Scripts/ci/package-apple-artifacts.sh all
;;
*)
echo "unknown apple runner command: ${command}" >&2
exit 64
;;
esac