From 3040223fd648b99077599cb134249dcbf8563286 Mon Sep 17 00:00:00 2001 From: tashda Date: Fri, 1 May 2026 12:40:50 +0200 Subject: [PATCH 1/3] Add Xcode Cloud ci_post_clone.sh to materialize signing config Generates Config/BuildSettings.local.xcconfig from workflow env vars (APP_BUNDLE_ID, APP_DEVELOPMENT_TEAM, APP_WIDGET_BUNDLE_SUFFIX) so Xcode Cloud archives sign with the right team and bundle ID instead of the public defaults. Co-Authored-By: Claude Opus 4.7 (1M context) --- ci_scripts/ci_post_clone.sh | 38 +++++++++++++++++++++++++++++++++++++ 1 file changed, 38 insertions(+) create mode 100755 ci_scripts/ci_post_clone.sh diff --git a/ci_scripts/ci_post_clone.sh b/ci_scripts/ci_post_clone.sh new file mode 100755 index 0000000..439bc88 --- /dev/null +++ b/ci_scripts/ci_post_clone.sh @@ -0,0 +1,38 @@ +#!/bin/sh +# Xcode Cloud runs this after cloning the repo, before xcodebuild. +# Generates Config/BuildSettings.local.xcconfig from environment variables +# defined in the Xcode Cloud workflow, since the real local xcconfig is +# gitignored and not available on Apple's runners. +# +# Required env vars (set in Xcode Cloud workflow → Environment Variables): +# APP_BUNDLE_ID e.g. com.tashda.shellbee +# APP_DEVELOPMENT_TEAM e.g. JQU2HR44D8 (mark as secret) +# APP_WIDGET_BUNDLE_SUFFIX e.g. widgets +# +# Optional (omit unless you want Sentry symbol upload from CI): +# SENTRY_DSN, SENTRY_ORG, SENTRY_PROJECT, SENTRY_AUTH_TOKEN + +set -eu + +if [ -z "${APP_BUNDLE_ID:-}" ] || [ -z "${APP_DEVELOPMENT_TEAM:-}" ] || [ -z "${APP_WIDGET_BUNDLE_SUFFIX:-}" ]; then + echo "ci_post_clone.sh: required env vars not set (APP_BUNDLE_ID, APP_DEVELOPMENT_TEAM, APP_WIDGET_BUNDLE_SUFFIX)" + exit 1 +fi + +REPO_ROOT="$(cd "$(dirname "$0")/.." && pwd)" +TARGET="$REPO_ROOT/Config/BuildSettings.local.xcconfig" + +{ + echo "APP_DEVELOPMENT_TEAM = $APP_DEVELOPMENT_TEAM" + echo "APP_BUNDLE_ID = $APP_BUNDLE_ID" + echo "APP_WIDGET_BUNDLE_SUFFIX = $APP_WIDGET_BUNDLE_SUFFIX" + echo "APP_WIDGET_BUNDLE_ID = \$(APP_BUNDLE_ID).\$(APP_WIDGET_BUNDLE_SUFFIX)" + echo "APP_TESTS_BUNDLE_ID = \$(APP_BUNDLE_ID).tests" + echo "APP_UI_TESTS_BUNDLE_ID = \$(APP_BUNDLE_ID).uitests" + [ -n "${SENTRY_DSN:-}" ] && echo "SENTRY_DSN = $SENTRY_DSN" + [ -n "${SENTRY_ORG:-}" ] && echo "SENTRY_ORG = $SENTRY_ORG" + [ -n "${SENTRY_PROJECT:-}" ] && echo "SENTRY_PROJECT = $SENTRY_PROJECT" + [ -n "${SENTRY_AUTH_TOKEN:-}" ] && echo "SENTRY_AUTH_TOKEN = $SENTRY_AUTH_TOKEN" +} > "$TARGET" + +echo "ci_post_clone.sh: wrote $TARGET" From 3fa30dba64f5b4e2b06b26f44211b137a91900a7 Mon Sep 17 00:00:00 2001 From: tashda Date: Fri, 1 May 2026 12:45:25 +0200 Subject: [PATCH 2/3] Rename Xcode Cloud env vars to avoid build-setting collision Xcode Cloud rejected APP_DEVELOPMENT_TEAM as 'invalid value' because DEVELOPMENT_TEAM is a reserved Xcode build setting. Renaming to SHELLBEE_* avoids the collision; the script still writes the canonical APP_* names into BuildSettings.local.xcconfig. Co-Authored-By: Claude Opus 4.7 (1M context) --- ci_scripts/ci_post_clone.sh | 20 ++++++++++++-------- 1 file changed, 12 insertions(+), 8 deletions(-) diff --git a/ci_scripts/ci_post_clone.sh b/ci_scripts/ci_post_clone.sh index 439bc88..95fc078 100755 --- a/ci_scripts/ci_post_clone.sh +++ b/ci_scripts/ci_post_clone.sh @@ -5,17 +5,21 @@ # gitignored and not available on Apple's runners. # # Required env vars (set in Xcode Cloud workflow → Environment Variables): -# APP_BUNDLE_ID e.g. com.tashda.shellbee -# APP_DEVELOPMENT_TEAM e.g. JQU2HR44D8 (mark as secret) -# APP_WIDGET_BUNDLE_SUFFIX e.g. widgets +# SHELLBEE_BUNDLE_ID e.g. com.tashda.shellbee +# SHELLBEE_TEAM_ID e.g. JQU2HR44D8 (mark as secret) +# SHELLBEE_WIDGET_SUFFIX e.g. widgets +# +# These are intentionally renamed (vs. APP_BUNDLE_ID / APP_DEVELOPMENT_TEAM) to +# avoid Xcode Cloud rejecting names that collide with reserved Xcode build +# settings like DEVELOPMENT_TEAM. # # Optional (omit unless you want Sentry symbol upload from CI): # SENTRY_DSN, SENTRY_ORG, SENTRY_PROJECT, SENTRY_AUTH_TOKEN set -eu -if [ -z "${APP_BUNDLE_ID:-}" ] || [ -z "${APP_DEVELOPMENT_TEAM:-}" ] || [ -z "${APP_WIDGET_BUNDLE_SUFFIX:-}" ]; then - echo "ci_post_clone.sh: required env vars not set (APP_BUNDLE_ID, APP_DEVELOPMENT_TEAM, APP_WIDGET_BUNDLE_SUFFIX)" +if [ -z "${SHELLBEE_BUNDLE_ID:-}" ] || [ -z "${SHELLBEE_TEAM_ID:-}" ] || [ -z "${SHELLBEE_WIDGET_SUFFIX:-}" ]; then + echo "ci_post_clone.sh: required env vars not set (SHELLBEE_BUNDLE_ID, SHELLBEE_TEAM_ID, SHELLBEE_WIDGET_SUFFIX)" exit 1 fi @@ -23,9 +27,9 @@ REPO_ROOT="$(cd "$(dirname "$0")/.." && pwd)" TARGET="$REPO_ROOT/Config/BuildSettings.local.xcconfig" { - echo "APP_DEVELOPMENT_TEAM = $APP_DEVELOPMENT_TEAM" - echo "APP_BUNDLE_ID = $APP_BUNDLE_ID" - echo "APP_WIDGET_BUNDLE_SUFFIX = $APP_WIDGET_BUNDLE_SUFFIX" + echo "APP_DEVELOPMENT_TEAM = $SHELLBEE_TEAM_ID" + echo "APP_BUNDLE_ID = $SHELLBEE_BUNDLE_ID" + echo "APP_WIDGET_BUNDLE_SUFFIX = $SHELLBEE_WIDGET_SUFFIX" echo "APP_WIDGET_BUNDLE_ID = \$(APP_BUNDLE_ID).\$(APP_WIDGET_BUNDLE_SUFFIX)" echo "APP_TESTS_BUNDLE_ID = \$(APP_BUNDLE_ID).tests" echo "APP_UI_TESTS_BUNDLE_ID = \$(APP_BUNDLE_ID).uitests" From 09a942b4aa1fd3a740ffec3a4c81d632c6d65dd0 Mon Sep 17 00:00:00 2001 From: tashda Date: Fri, 1 May 2026 12:48:46 +0200 Subject: [PATCH 3/3] Bump MARKETING_VERSION to 1.5.1 Patch release to ship the Xcode Cloud signing-config script through the proper tag-triggered release pipeline. Co-Authored-By: Claude Opus 4.7 (1M context) --- Shellbee.xcodeproj/project.pbxproj | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/Shellbee.xcodeproj/project.pbxproj b/Shellbee.xcodeproj/project.pbxproj index 2ce386f..b383476 100644 --- a/Shellbee.xcodeproj/project.pbxproj +++ b/Shellbee.xcodeproj/project.pbxproj @@ -830,7 +830,7 @@ "$(inherited)", "@executable_path/Frameworks", ); - MARKETING_VERSION = 1.5.0; + MARKETING_VERSION = 1.5.1; PRODUCT_BUNDLE_IDENTIFIER = "$(APP_BUNDLE_ID)"; PRODUCT_NAME = "$(TARGET_NAME)"; STRING_CATALOG_GENERATE_SYMBOLS = YES; @@ -871,7 +871,7 @@ "$(inherited)", "@executable_path/Frameworks", ); - MARKETING_VERSION = 1.5.0; + MARKETING_VERSION = 1.5.1; PRODUCT_BUNDLE_IDENTIFIER = "$(APP_BUNDLE_ID)"; PRODUCT_NAME = "$(TARGET_NAME)"; PROVISIONING_PROFILE_SPECIFIER = ""; @@ -911,7 +911,7 @@ "@executable_path/Frameworks", "@executable_path/../../Frameworks", ); - MARKETING_VERSION = 1.5.0; + MARKETING_VERSION = 1.5.1; PRODUCT_BUNDLE_IDENTIFIER = "$(APP_WIDGET_BUNDLE_ID)"; PRODUCT_NAME = "$(TARGET_NAME)"; SKIP_INSTALL = YES; @@ -953,7 +953,7 @@ "@executable_path/Frameworks", "@executable_path/../../Frameworks", ); - MARKETING_VERSION = 1.5.0; + MARKETING_VERSION = 1.5.1; PRODUCT_BUNDLE_IDENTIFIER = "$(APP_WIDGET_BUNDLE_ID)"; PRODUCT_NAME = "$(TARGET_NAME)"; PROVISIONING_PROFILE_SPECIFIER = "";