From Build Swift Apps
Analyzes Xcode build performance by benchmarking, running specialist diagnostics, and generating prioritized optimization plans. Use for speeding up builds or full build audits.
How this skill is triggered — by the user, by Claude, or both
Slash command
/build-swift-apps:xcode-build-strategistThe summary Claude sees in its skill listing — used to decide when to auto-load this skill
Bundled commands use `$PLUGIN_ROOT` (`$env:PLUGIN_ROOT` in PowerShell; same path suffix) for the plugin root. Set it once: use the host's plugin-root variable when defined (Claude Code: `PLUGIN_ROOT="$CLAUDE_PLUGIN_ROOT"`), otherwise the absolute path of this plugin's root directory.
Bundled commands use $PLUGIN_ROOT ($env:PLUGIN_ROOT in PowerShell; same path suffix) for the plugin root. Set it once: use the host's plugin-root variable when defined (Claude Code: PLUGIN_ROOT="$CLAUDE_PLUGIN_ROOT"), otherwise the absolute path of this plugin's root directory.
Entry point for end-to-end Xcode build optimization. Phase 1 recommends only; Phase 2 executes only after explicit approval.
.build-benchmark/.python3 ../../shared/build-optimization/scripts/benchmark_builds.py \
--project App.xcodeproj --scheme MyApp --configuration Debug \
--destination "platform=iOS Simulator,name=<latest available iPhone simulator>,OS=latest" \
--output-dir .build-benchmark
Add --touch-file path/to/File.swift for real incremental rebuilds.timing_summary_categories; cached_clean runs when COMPILATION_CACHE_ENABLE_CACHING=YES; variance noted when max-min exceeds 20% of median.xcode-compile-profilerxcode-project-auditorswiftpm-build-inspector.build-benchmark/optimization-plan.md:
python3 "$PLUGIN_ROOT/skills/xcode-build-strategist/scripts/generate_optimization_report.py" \
--benchmark .build-benchmark/<artifact>.json \
--project-path App.xcodeproj \
--diagnostics .build-benchmark/<diagnostics>.json \
--output .build-benchmark/optimization-plan.md
After approval, read checked items from .build-benchmark/optimization-plan.md, delegate to xcode-build-tuner, append verification medians/deltas to the plan, and report before/after results.
PhaseScriptExecution, CompileAssetCatalog, CodeSign, planning, or emit-module work can outrank individual Swift file hotspots.Use these impact phrases:
COMPILATION_CACHE_ENABLE_CACHING: "Measured 5-14% faster clean builds across tested projects; benefits compound with persistent DerivedData."For iOS simulator benchmarks, resolve an installed iPhone/iOS pair first and prefer OS=latest when accepted. For macOS use --destination "platform=macOS". For watchOS/tvOS use an installed simulator. If local runtime inspection fails, ask or note the fallback.
Lead with wall-clock before/after. Include baseline/post medians, absolute and percentage deltas, changes made or intentionally skipped, confidence/noise notes, and a plain warning when workload improved but wait time did not.
References: references/orchestration-report-template.md, ../../shared/build-optimization/references/benchmark-artifacts.md, recommendation-format.md, and build-settings-best-practices.md.
npx claudepluginhub xopoko/build-swift-apps --plugin build-swift-appsOrchestrates Xcode build optimization with benchmarking, specialist analysis, prioritization, approval request, and delegation to xcode-build-fixer. Use for end-to-end build speedup or full audit.
Implements approved Xcode build optimizations including build settings, script phases, Swift compilation patterns, and SwiftPM graph fixes, with re-benchmarking to verify performance.
Guides completion of development work by verifying tests, detecting environment, and presenting structured options for merge, PR, or cleanup.