Skip to content
Development
Skill

/debug-generated-project

Debugs issues users encounter with Tuist-generated projects by reproducing the scenario locally, building Tuist from source when needed, and triaging whether it is a bug, misconfiguration, or something that needs team input. Use when users report generation failures, build

From plugin
tuist
5.9k13 skills50 agents

Claude Code

$ npx -y skills add tuist/tuist --skill debug-generated-project --agent claude-code

SKILL.md

debug-generated-project.SKILL.md
name: debug-generated-project
description: Debugs issues users encounter with Tuist-generated projects by reproducing the scenario locally, building Tuist from source when needed, and triaging whether it is a bug, misconfiguration, or something that needs team input. Use when users report generation failures, build errors after generation, or unexpected project behavior.

Debug Tuist Project Issue

Quick Start

1. Ask the user to describe the issue and the project setup (targets, dependencies, configurations, platform). 2. Confirm the issue exists with the latest release by running `mise exec tuist@latest -- tuist generate` against a reproduction project. 3. If confirmed, clone the Tuist repository and build from source to test against main. 4. Triage: fix the bug and open a PR, advise on misconfiguration, or recommend the user files an issue with a reproduction.

Step 1: Gather Context

Ask the user for:

  • What command they ran (e.g. `tuist generate`)
  • The error message or unexpected behavior
  • **When the issue happens**: generation time, compile time, or runtime (app launch or later)
  • Their project structure: targets, platforms, dependencies (SwiftPM, XCFrameworks, local packages)
  • Their `Project.swift` and `Tuist.swift` content (or relevant excerpts)
  • Their Tuist version (`tuist version`)

The answer to "when" determines the verification strategy:

  • **Generation time**: the issue might be a Tuist bug or a project misconfiguration. Reproduce with `tuist generate`.
  • **Compile time**: the generated project has incorrect build settings, missing sources, or wrong dependency wiring. Reproduce with `xcodebuild build` after generation.
  • **Runtime**: the app builds but crashes or misbehaves on launch or during use. Reproduce by installing and launching on a simulator.

Step 2: Reproduce with the latest release

Before investigating the source code, confirm the issue is not already fixed in the latest release.

Set up a temporary reproduction project

REPRO_DIR=$(mktemp -d)
cd "$REPRO_DIR"

Create minimal `Tuist.swift`, `Project.swift`, and source files that reproduce the user's scenario. Keep it as small as possible while still triggering the issue.

Run generation with the latest Tuist release

mise exec tuist@latest -- tuist generate --no-open --path "$REPRO_DIR"

If the issue involves dependencies, install them first:

mise exec tuist@latest -- tuist install --path "$REPRO_DIR"

Check the result

  • If generation succeeds and the issue is gone, tell the user to update to the latest version.
  • If the issue persists, continue to Step 3.

Step 3: Build Tuist from Source

Clone the repository and build the `tuist` executable and `ProjectDescription` library from source to test against the latest code on `main`.

TUIST_SRC=$(mktemp -d)
git clone --depth 1 https://github.com/tuist/tuist.git "$TUIST_SRC"
cd "$TUIST_SRC"
swift build --product tuist --product ProjectDescription --replace-scm-with-registry

The built binary will be at `.build/debug/tuist`. Use it to test the reproduction project:

"$TUIST_SRC/.build/debug/tuist" generate --no-open --path "$REPRO_DIR"

If the issue is fixed on main

Tell the user the fix is already on `main`, and it hasn't been released, tell them it'll be in the nest release and point them to the relevant commit if you can identify it.

If the issue persists on main

Continue to Step 4.

Step 4: Triage the Issue

Investigate the Tuist source code to understand why the issue occurs.

Outcome A: It is a bug

1. Identify the root cause in the source code. 2. Apply the fix. 3. Verify by rebuilding and running against the reproduction project:

   cd "$TUIST_SRC"
   swift build --product tuist --product ProjectDescription --replace-scm-with-registry
   "$TUIST_SRC/.build/debug/tuist" generate --no-open --path "$REPRO_DIR"

4. Zip the reproduction project and include it in the PR:

   cd "$REPRO_DIR" && cd ..
   zip -r reproduction.zip "$(basename "$REPRO_DIR")" -x '*.xcodeproj/*' -x '*.xcworkspace/*' -x 'Derived/*' -x '.build/*'

5. Open a PR on the Tuist repository with:

  • The fix
  • The zipped reproduction project attached or committed as a fixture
  • A clear description of the root cause and how to verify the fix

Outcome B: It is a misconfiguration

Tell the user what is wrong and how to fix it. Common misconfigurations:

  • Missing `tuist install` before `tuist generate` when using external dependencies
  • Incorrect source or resource globs that exclude or double-include files
  • Mismatched build configurations between the project and external dependencies
  • Wrong product types for dependencies (static vs dynamic)
  • Missing `-ObjC` linker flag for Objective-C dependencies
  • Using `sources` and `resources` globs together with `buildableFolders`

Provide the corrected manifest snippet so the user can apply the fix directly.

Outcome C: Unclear or needs team input

If you cannot determine whether it is a bug or misconfiguration, recommend the user:

1. Open a GitHub issue at https://github.com/tuist/tuist/issues with:

  • The reproduction project (zipped)
  • The error output
  • Their Tuist version and environment details

Provide a summary of what you investigated and what you ruled out, so the user does not have to repeat the triage.

Build Verification

When testing a fix, always verify the full cycle:

# Build the patched tuist
cd "$TUIST_SRC"
swift build --product tuist --product ProjectDescription --replace-scm-with-registry

# Install dependencies if needed
"$TUIST_SRC/.build/debug/tuist" install --path "$REPRO_DIR"

# Generate the project
"$TUIST_SRC/.build/debug/tuist" generate --no-open --path "$REPRO_DIR"

# Build the generated project
xcodebuild build \
  -workspace "$REPRO_DIR"/*.xcworkspace \
  -scheme <scheme> \
  -destination "platform=iOS Simulator,name=iPhone 16 Pro"

Runti

Read more
@tuist
Ships withtuist

Tuist is a build platform for engineering teams and their coding agents. It works with Xcode, Gradle, Bazel, Elixir, and Rust builds. Features vary by toolchain: Rust compilation caching is experimental, and Once support is in canary.

5.9k13 skills50 agents
Get the whole plugin

Stars on GitHub

Momentum

stars in total
5.9k
Star history of tuist/tuist on GitHub, a chart by star-history.com

Other skills on tuist.

verifying-work-with-tuist

verifying-work-with-tu…

Checks a change against the project's history in Tuist before calling it done, so that flaky tests, failures that already happen…

@tuist@tuistInstall Skill
analyze-selective-testing

analyze-selective-test…

Analyzes Xcode selective testing effectiveness for a test run, showing which test targets were skipped or ran, and diagnosing…

@tuist@tuistInstall Skill
compare-builds

compare-builds

Compares two Xcode build runs to identify duration regressions, cache changes, and new issues. Can be invoked with build IDs,…

@tuist@tuistInstall Skill
compare-bundles

compare-bundles

Compares two app bundles to identify size changes, new or removed artifacts, and platform differences. Can be invoked with bundle…

@tuist@tuistInstall Skill
compare-cache-runs

compare-cache-runs

Compares two `tuist cache` runs to identify cache hit rate changes and root-cause analysis of cache invalidation. Can be invoked…

@tuist@tuistInstall Skill
compare-generations

compare-generations

Compares two `tuist generate` runs to identify cache hit rate changes and root-cause analysis of cache invalidation. Can be…

@tuist@tuistInstall Skill

More skills from other plugins.

brainstorming
Auto-invoked

brainstorming

You MUST use this before any creative work - creating features, building components, adding functionality, modifying behavior, or…

@obra@obraInstall Skill
ask-matt

ask-matt

Ask which skill or flow fits your situation. A router over the skills in this repo.

skills3w309k
@mattpocock@mattpocockInstall Skill
accessibility
Auto-invoked

accessibility

Design, implement, and audit accessible UI to WCAG 2.2 Level AA across Web, iOS, and Android — semantic ARIA roles and labels,…

ecc3w293k
@affaan-m@affaan-mInstall Skill
compiler-commit

compiler-commit

Use when you want to verify compiler changes and commit with the correct convention. Runs tests, lint, and format, then commits…

react2w252k
@facebook@facebookInstall Skill

Questions about debug-generated-project.

Which coding agents can use debug-generated-project?
debug-generated-project installs in Claude Code, Codex, Cursor, Gemini CLI, GitHub Copilot, OpenCode and Windsurf with the skills CLI, using each agent's flag shown on this page. Flowy's auto-invocation, which fires a skill when your prompt matches, runs in Claude Code only.