원클릭으로
compare-builds
// Compares two Xcode build runs to identify duration regressions, cache changes, and new issues. Can be invoked with build IDs, dashboard URLs, or branch names (e.g. `tuist compare-builds --base main --head feature-branch`).
// Compares two Xcode build runs to identify duration regressions, cache changes, and new issues. Can be invoked with build IDs, dashboard URLs, or branch names (e.g. `tuist compare-builds --base main --head feature-branch`).
Project-specific PR-review rules for the tuist/tuist Elixir codebases (server, cache, processor, xcode_processor, tuist_common, noora). Focuses on the things only this repo knows — authorization invariants, tenancy, write-only ClickHouse, Mimic placement, migration timestamptz, data-export updates, marketing changelog entries, and i18n.
Project-specific PR-review rules for the tuist/tuist Swift codebase (cli). Focuses on the things only this repo knows — preferring value types, the testing framework choice, and migration of XCTest to Swift Testing.
Guides day-to-day work in Tuist-generated Xcode workspaces, including generation, build and test commands, and buildable folders. Use when working in a Tuist-generated project or when users mention `tuist generate`, `xcodebuild test`, or generated workspaces.
Migrates existing Xcode projects to Tuist generated workspaces with build and run validation, external dependency mapping, and migration checklists. Use when adopting Tuist for an existing app or converting a hand-edited Xcode project to generated projects.
Analyzes Xcode selective testing effectiveness for a test run, showing which test targets were skipped or ran, and diagnosing regressions in test selection. Can compare two test runs to identify what changed.
Compares two Gradle build runs to identify duration regressions, cache changes, and task outcome differences. Can be invoked with build IDs, dashboard URLs, or branch names.
| name | compare-builds |
| description | Compares two Xcode build runs to identify duration regressions, cache changes, and new issues. Can be invoked with build IDs, dashboard URLs, or branch names (e.g. `tuist compare-builds --base main --head feature-branch`). |
You'll typically receive two build identifiers (IDs, dashboard URLs, or branch names). Follow these steps:
tuist build list --json to find builds on each branch.tuist build show <build-id> --json for both base and head builds.tuist build xcode target list <id> --json), issues (tuist build xcode issue list <id> --json), and cache tasks (tuist build xcode cache-task list <id> --json).If only one identifier is provided, use the project's default branch as the baseline.
Fetch each directly:
tuist build show <base-id> --json
tuist build show <head-id> --json
List recent builds on each branch and pick the latest:
tuist build list --git-branch <base-branch> --json --page-size 1
tuist build list --git-branch <head-branch> --json --page-size 1
Then fetch full details with tuist build show <id> --json.
main).git rev-parse --abbrev-ref HEAD.After fetching both builds with tuist build show <id> --json, drill down into sub-resources for a deeper comparison.
tuist build xcode target list <base-id> --json
tuist build xcode target list <head-id> --json
Look for targets that changed status (e.g., success to failure) or had significant duration changes.
tuist build xcode issue list <base-id> --json
tuist build xcode issue list <head-id> --json
Look for new warnings or errors introduced in the head build.
tuist build xcode cache-task list <base-id> --json
tuist build xcode cache-task list <head-id> --json
Identify which specific targets had cache misses or hits and whether that changed between builds.
After fetching both builds, compare:
| Metric | What to check |
|---|---|
duration | Flag if head is >10% slower than base |
status | Flag if base succeeded but head failed |
cacheable_tasks_count | Note if task count changed |
cacheable_task_local_hits_count | Compare local hit counts |
cacheable_task_remote_hits_count | Compare remote hit counts |
| Cache hit rate | (local_hits + remote_hits) / cacheable_tasks_count * 100 |
category | Note if one is clean and the other incremental (makes duration comparison less meaningful) |
scheme / configuration | Ensure both builds used the same scheme and configuration for a fair comparison |
Compute the cache miss delta: base_misses - head_misses. Positive means head has fewer misses (improvement). Negative means regression.
If the head build is significantly slower:
category differs (clean vs incremental builds are not directly comparable).Compare cache statistics:
Compare environment details:
xcode_version and macos_version: Different versions can affect build times and cache validity.is_ci: CI vs local builds may have different performance characteristics.git_branch and git_commit_sha: Verify the builds are from the expected commits.Produce a summary with:
Example:
Build Comparison: base (abc123 on main) vs head (def456 on feature-x)
Duration: 45.2s -> 62.8s (+39%) -- REGRESSION
Cache hit rate: 85% -> 72% (-13%) -- 8 new cache misses
Status: success -> success
Root cause: Cache hit rate dropped due to 8 targets with invalidated caches.
The dependency hash changed for FeatureModule, cascading to 7 downstream targets.
Recommendations:
- Investigate why FeatureModule's cache was invalidated
- Consider splitting large targets to reduce cascade impact