/axiom:fix-build
Diagnose and fix Xcode build failures using environment-first diagnostics (launches the build-fixer agent).
Command
bash
/axiom:fix-buildWhat It Does
Checks the build environment before looking at code, preventing "rabbit hole" debugging of ghost issues.
- Running Builds – Lists running
xcodebuildprocesses and checks who owns them before stopping anything - Derived Data – Clears only this project's Derived Data folder, and only for a confirmed stale-build cause
- Simulator State – Resets only the stuck simulator, leaving other sessions' simulators alone
- SPM Cache – Validates package resolution state
- Saved Build Log – Reads the full build log (saved by axbuild, or a plain log file where axbuild isn't available) before deciding whether a rebuild is needed
Before anything destructive, it stops and shows you the cause, the evidence and the exact command, so you can approve it.
When to Use
- You see
BUILD FAILEDbut the error makes no sense - "No such module" errors appear after switching branches
- "Unable to boot simulator" errors occur
- Xcode is stuck indexing or processing files indefinitely
- You suspect a "ghost in the machine" rather than a code error
Related
- build-fixer – The agent this command launches
- /axiom:optimize-build – Speed up builds after fixing them
- xcode-debugging – The manual skill behind this agent