Skip to content
CAI
Software that uses CAICheck a score

yonaskolb/XcodeGen

64.0

Adequate · 27 September 2026

10.2k

lines of production code

Swift

primary language

4

measurements over time

CAI band scale
CAI trend line
CAI lens gauges

What this system is

XcodeGen is a command-line tool that generates Xcode project files from YAML or JSON specifications, allowing teams to keep project configurations in version control and avoid merge conflicts. It supports complex project structures by integrating with Carthage and Swift Package Manager, managing dependencies, build rules, and shared schemes. The system provides utilities for caching, inspecting specifications, and executing pre- and post-generation hooks to streamline the development workflow.

How it got here

2017 — Initial release and architectural modernization

11 changes.

This period marks the initial release of XcodeGen 2.46.0, establishing the core engine for generating Xcode projects from YAML or JSON specifications. The work involved a significant architectural refactor to modernize the codebase, including upgrading to Swift 5.9, restructuring modules, and implementing comprehensive test coverage for project generation and specification parsing.

2018–2019 — CLI restructuring and test expansion

17 changes.

The project introduced a new XcodeGenCLI executable with a restructured command interface, adding cache and dump subcommands alongside enhanced generation hooks. This period also focused heavily on expanding test coverage by creating comprehensive fixtures for Carthage and SPM integration, while implementing performance benchmarks and utility helpers to validate project generation logic.

2021–2026 — XcodeGenCore library and test infrastructure

4 changes.

This period focused on introducing the XcodeGenCore library, which provides core utilities such as parallel file search, atomic property wrappers, and MD5 hashing to improve stability and performance. Comprehensive unit tests were added for these new core functions, alongside the creation of test fixtures for SPM and local package scenarios to support broader testing capabilities.

Features

Initial release of XcodeGen 2.46.0

XcodeGen is a command-line tool that generates Xcode projects from a YAML or JSON spec, eliminating merge conflicts by keeping the .xcodeproj out of version control. This initial release includes the core generation engine, a Makefile for building and installing the tool, and comprehensive documentation. Key features include automatic source directory parsing, support for multiple spec files, and integration with Carthage and Swift Package Manager. The release also introduces scheme build options like \buildArchitectures\ (defaulting to 'Match Run Destination'), fixes for synced folder source paths and nested target attribute serialization, and updates to the XcodeProj dependency.

(repo-wide) · high confidence

Introduce ProjectSpec module with comprehensive project configuration models

The project configuration logic has been reorganized into a new \ProjectSpec\ module, introducing a complete set of data models for defining Xcode projects. This includes \AggregateTarget\ for aggregate targets, \Breakpoint\ for shared breakpoint definitions, \BuildRule\ and \BuildScript\ for build phase customization, \Dependency\ for managing target, framework, Carthage, SDK, and package dependencies, and \FileType\ for mapping file extensions to build phases. The module also provides \DeploymentTarget\ for per-platform versioning, \GroupOrdering\ for custom group sorting, and robust JSON/YAML encoding and decoding capabilities via \JSONObjectConvertible\ and \JSONEncodable\ protocols, establishing the foundational schema for project specification.

Sources/ProjectSpec · high confidence

Introduction of XcodeGenCLI executable with new command structure

The XcodeGenCLI module introduces the main executable entry point for the XcodeGen tool, establishing a new command-line interface structure. It registers the primary 'generate' command alongside two new subcommands: 'cache' and 'dump', allowing users to manage generation caches and inspect project specifications directly from the CLI. The implementation utilizes SwiftCLI 6.0 for argument parsing and routing, and includes specific error handling for missing project specs, parsing failures, and validation issues to provide clearer feedback during project generation.

Sources/XcodeGenCLI · high confidence

New distribution and fixture management scripts

The project now includes a set of new shell scripts to handle binary distribution and test fixture generation. The \archive.sh\ script packages the executable, setting presets, and license into a ZIP file and prints its SHA-256 hash, while \install.sh\ copies the binary and presets to a specified prefix (defaulting to /usr/local). Additionally, \gen-fixtures.sh\ automates the generation of test fixtures for XcodeGen, Carthage, and SPM projects, supported by \build-fixtures.sh\ to build them and \diff-fixtures.sh\ to detect changes in the generated fixtures.

scripts · high confidence

Support for Xcode 16 project format and breakpoint generation

XcodeGen now supports generating projects compatible with Xcode 16 (including versions 14.0, 15.0, 15.3, 16.0, and 16.3) via the new ProjectFormat enum, which maps to the correct object versions and compatibility strings. Additionally, the tool can now generate breakpoint lists for shared and user scheme data, allowing developers to persist breakpoint configurations directly in the generated project.

Sources/XcodeGenKit · high confidence

Removals

Removal of test\_project.xcodeproj project file

The Xcode project configuration file for the test project (test\_project.xcodeproj) has been deleted. This removes the build settings, source file references (including main.swift, Decoding.swift, Generator.swift, Scheme.swift, and Spec.swift), and the 'Axis iOS' target definition from the workspace, effectively removing this specific test project from the build system.

_test\project.xcodeproj · high confidence

Behavioural changes

Add custom test helper utilities and Linux-specific skip logic

The TestSupport module now includes a new TestHelpers.swift file providing custom assertion helpers (doThrowing, unwrap, expectError) and an ArrayExpectation type to improve test readability and error reporting. It also adds a skipIfNecessary() function that automatically skips tests on Linux when running Swift versions prior to 6.0.2 to avoid known PropertyListDecoder issues.

Sources/TestSupport · high confidence

Introduce XcodeGenCore library with parallel file search and stability fixes

The XcodeGenCore module has been introduced to provide core utilities, including a parallel glob implementation that speeds up file inclusion checks on macOS and a sorted-array binary search for efficient lookups. This change also adds thread-safe atomic property wrappers and MD5 hashing capabilities, while addressing segmentation faults and crashes in the file-globbing logic to improve overall stability.

Sources/XcodeGenCore · medium confidence

New cache, dump, and enhanced generate commands with pre/post hooks

The CLI now includes a dedicated \cache\ command to write the project spec cache to a file, and a \dump\ command to output the resolved project spec in various formats (JSON, YAML, Swift dump, etc.) to stdout or a file. The \generate\ command has been updated to support a \--only-plists\ flag for generating only plist files, and it now executes \preGenCommand\ and \postGenCommand\ hooks at the appropriate stages of the generation process. Additionally, the \generate\ command uses the \USER\ environment variable instead of \LOGNAME\ for project generation, and the base \ProjectCommand\ now supports specifying multiple spec files via comma-separated paths.

Sources/XcodeGenCLI/Commands · high confidence

Refactor CLI entry point to use XcodeGenCLI and Version modules

The main entry point for the XcodeGen tool has been refactored to replace the previous Commander-based command structure with a dedicated XcodeGenCLI module. This change removes hardcoded test paths and manual spec parsing logic from the entry point, delegating execution to the new CLI wrapper which handles argument parsing and execution flow. The application version is now managed via the Version module, ensuring consistent version reporting.

Sources/XcodeGen · high confidence

Test coverage

Added Carthage build fixtures for testing; Added Carthage project workspace fixture for testing; Added Carthage test fixture with multi-platform framework configuration; Added SPM test fixture for static library linking; Added SPM test fixture with local package and static library support; Added SPM test fixture workspace files; Added comprehensive test coverage for XcodeGenKit project generation; Added performance tests for project generation and caching; Added test coverage for SPM fixture scheme generation; Added test coverage for spec validation and loading behavior; Added test fixture for LocalPackage; Added test fixtures for FooDomain and FooUI modules; Added test fixtures for relative path resolution in includes; Added test fixtures for scheme generation and management; Added test fixtures for spec parsing and merging behavior; Added tests for Xcode project generation fixtures; Added unit tests for core utility functions; Expanded TestProject fixture with App Clips, StoreKit, and CoreData support; Removal of placeholder XcodeGen test file; Simplified Linux test runner configuration; Updated Carthage test fixture to Xcode project format 77.

Dependencies

Upgrade to Swift 5.9 and modernize dependency management

The project has been upgraded to Swift 5.9 (from 3.1) and now requires macOS 11. This change migrates the dependency resolution from legacy major/minor version constraints to modern semantic versioning (using \from:\ and \exact:\) and updates the core \XcodeProj\ library to version 9.14.0. Additionally, new dependencies such as \SwiftCLI\, \Version\, and \ArtifactBundleGen\ have been integrated, and the package structure has been reorganized to include distinct \XcodeGenCLI\, \ProjectSpec\, and \XcodeGenCore\ targets.

(dependencies) · high confidence

Written by watchdog.canine.dev from the codebase's own history, inside the signed delivery this page is composed from.

How this codebase got here

Score

  • CAI 50 → 64 (+14.4)
  • Rubric changed (rubric-2026.08.15 → rubric-2026.09.15) — scores are not directly comparable.

Lenses

  • Code Health 100 → 74 (-25.6)
  • Architecture 98 (new)
  • Maturity 55 → 61 (+5.7)
  • Readiness 27 → 67 (+39.4)
  • Security 85 → 60 (-25.4)

Resolved (6)

  • Dimension evaluation failed
  • No automated tests
  • No exposed public API
  • No tests found
  • Test reliability not included
  • The Usage document mentions CocoaPods, Carthage, Swift Package Manager, and SDK dependencies but does not link to a dedicated Dependencies or Installation section. (Docs/Usage.md)

New (120)

  • Assertions commented out: testExample (Tests/Fixtures/SPM/SPMTests/SPMTests.swift)
  • Assertions commented out: testExample (Tests/Fixtures/TestProject/App_Clip_Tests/TestProjectTests.swift)
  • Assertions commented out: testExample (Tests/Fixtures/TestProject/App_Clip_UITests/TestProjectUITests.swift)
  • Assertions commented out: testExample (Tests/Fixtures/TestProject/App_iOS_Tests/TestProjectTests.swift)
  • Assertions commented out: testExample (Tests/Fixtures/TestProject/App_iOS_UITests/TestProjectUITests.swift)
  • Assertions commented out: testExample (Tests/Fixtures/TestProject/App_macOS_Tests/TestProjectTests.swift)
  • CarthageDependencyResolver.dependencies (cognitive 54) (Sources/XcodeGenKit/CarthageDependencyResolver.swift)
  • CarthageDependencyResolver.dependencies (cyclomatic 16) (Sources/XcodeGenKit/CarthageDependencyResolver.swift)
  • ClassTooLong: PBXProjGenerator (Sources/XcodeGenKit/PBXProjGenerator.swift)
  • ClassTooLong: SourceGenerator (Sources/XcodeGenKit/SourceGenerator.swift)
  • Coverage not measured — Swift suite
  • Duplicated block (10 lines × 3) (Sources/ProjectSpec/DeploymentTarget.swift)
  • Duplicated block (12 lines × 4) (Sources/ProjectSpec/Scheme.swift)
  • Duplicated block (12 lines × 5) (Sources/ProjectSpec/BuildScript.swift)
  • Duplicated block (12 lines × 6) (Sources/ProjectSpec/Scheme.swift)
  • Duplicated block (12–13 lines × 3) (Sources/XcodeGenKit/PBXProjGenerator.swift)
  • Duplicated block (13 lines × 2) (Sources/ProjectSpec/BuildScript.swift)
  • Duplicated block (13 lines × 2) (Sources/ProjectSpec/TargetReference.swift)
  • Duplicated block (14 lines × 2) (Sources/ProjectSpec/Scheme.swift)
  • Duplicated block (5 lines × 2) (Sources/ProjectSpec/Scheme.swift)
  • …and 100 more

Changes since last survey

  • 7 commits — 5 feature/other, 2 fixes

By area

  • (root) — 3 commits
  • Tests/Fixtures — 2 commits
  • Sources/XcodeGenKit — 1 commit
  • Tests/XcodeGenKitTests — 1 commit

Notable commits

  • fix: Fix non-deterministic/incorrect serialization of nested target attributes (e.g. SystemCapabilities) (#1639)
  • fix: Fix syncedFolder path being relative to the spec directory instead of the project directory (#1636)
  • change: Add missing 2.46.0 changelog entry for #1628
  • change: Add scheme build architecture overrides (#1642)
  • change: Document how to add capability (#1644)
  • change: Update changelog with changes since 2.46.0
  • change: Use a dedicated local package in the SPM fixture

Written by watchdog.canine.dev from the codebase's own history, inside the signed delivery this page is composed from.

Survey your own repository

yonaskolb/XcodeGen was measured the same way every project in this corpus was: the same rubric, at a pinned commit, with the result published in full. Point a surveyor at a repository you know and see whether you agree with it.

About this page

  • The score is its most recent published measurement, taken on 27 September 2026 at a pinned commit. It is not a live figure and does not change until the project is measured again.
  • Measured at commit 366592bc5be446b427fc8e2a21520344460f96ab — the exact code this score is about.
  • Scored under rubric-2026.09.15 — the same rubric and the same method as every other entry in this index.
  • Measured by watchdog.canine.dev using codehealth-analyzer preprod-d00c643c3f66.