From f6cc1b8fa46cb306bd801024b682cd2cf5234311 Mon Sep 17 00:00:00 2001 From: Brent Perteet Date: Mon, 24 Aug 2026 19:23:23 -0500 Subject: [PATCH] ci: archive unsigned iOS app bundle --- scripts/ci/build-ios-unsigned.sh | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/scripts/ci/build-ios-unsigned.sh b/scripts/ci/build-ios-unsigned.sh index 99caecb..b2e182a 100755 --- a/scripts/ci/build-ios-unsigned.sh +++ b/scripts/ci/build-ios-unsigned.sh @@ -7,6 +7,9 @@ developer_dir="${DEVELOPER_DIR:-/Applications/Xcode.app/Contents/Developer}" project="${repo_dir}/FieldLogger/FieldLogger.csproj" runtime_identifier="${IOS_RUNTIME:-ios-arm64}" nuget_cache="${UM_TRACE_NUGET_CACHE:-${TMPDIR:-/tmp}/um-trace-ci-nuget}" +app_bundle="${repo_dir}/FieldLogger/bin/Debug/net9.0-ios/${runtime_identifier}/FieldLogger.app" +artifacts_dir="${repo_dir}/artifacts/ios" +artifact_name="UMTrace-unsigned-${runtime_identifier}.app.zip" export DEVELOPER_DIR="${developer_dir}" export NUGET_HTTP_CACHE_PATH="${NUGET_HTTP_CACHE_PATH:-${nuget_cache}/http-cache}" @@ -38,3 +41,20 @@ mkdir -p "${NUGET_HTTP_CACHE_PATH}" -p:CodesignKey= \ -p:CodesignProvision= \ --no-restore + +if [[ ! -d "${app_bundle}" ]]; then + echo "Unsigned app bundle was not created at ${app_bundle}." >&2 + exit 3 +fi + +mkdir -p "${artifacts_dir}" +ditto -c -k --sequesterRsrc --keepParent \ + "${app_bundle}" \ + "${artifacts_dir}/${artifact_name}" + +( + cd "${artifacts_dir}" + shasum -a 256 "${artifact_name}" > "${artifact_name}.sha256" +) + +echo "Archived unsigned iOS app: ${artifacts_dir}/${artifact_name}"