Setup Apple App
| This documentation was generated with the assistance of AI. Please report any inaccuracies. |
Generate a complete, buildable native Apple application scaffold — a project-generator manifest (XcodeGen’s
project.yml, or Tuist’s Project.swift + Tuist.swift) declaring one application target <AppName>-<Platform>
per selected platform (iOS/iPadOS, macOS, watchOS, visionOS), a UI-framework-free Packages/Core local SwiftPM
package (Models/, Services/, plus ViewModels/ for MVVM or Controllers/ + a passive-view protocol for MVC)
whose Swift Testing suite covers 100% of its lines, the per-platform UI layer (SwiftUI everywhere, or programmatic
UIKit for the iOS/iPadOS target), per-platform Swift Testing unit-test and XCUITest UI-test targets, lint/format
config, a .ui-quality.yml, an optional gated fastlane/Fastfile, and sonar-project.properties — from the templates in the skill’s
reference/ files. It announces whether it
is scaffolding from scratch or updating an existing app, and warns and asks Update / Keep as is / Replace / Stop for
each of its files that already exists.
Purpose
iru-setup-apple-app bootstraps a new native Apple application from a house template: one XcodeGen or Tuist
manifest per repository, one application target per selected platform with SWIFT_STRICT_CONCURRENCY = complete,
the app’s MARKETING_VERSION/CURRENT_PROJECT_VERSION and a pinned unit-test host, a shared Packages/Core package
(Foundation + Observation only) that holds all testable logic outside any UI framework, and per-platform Swift
Testing/XCUITest targets driven by a --uitesting launch argument and accessibility identifiers on every control.
Following the catalog’s UI contract (see Building user interfaces), the
UI tests also capture the sample screen in every left-to-right/right-to-left × light/dark cell into
.ui-screenshots/ through a shared Tests/Support/UIScreenshots.swift helper, and run
performAccessibilityAudit() at the level configured in .ui-quality.yml.
With ui: uikit the iOS/iPadOS target becomes a programmatic UIKit app — AppDelegate + UIWindowSceneDelegate
with a scene manifest (mandatory with the 27 SDK), a UINavigationController root and a code-laid-out
UIViewController, no storyboards — backed by an MVC controller core (recommended) or an MVVM view model rendered
through UIKit Observation tracking (UIObservationTrackingEnabled added below iOS 26); watchOS, visionOS and macOS
targets always stay SwiftUI. visionOS is a native SwiftUI target, not "Designed for iPad"; tvOS, Mac Catalyst and
compatibility destinations are not supported. The resulting layout is the scaffold contract the Swift coding and
gate skills, iru-explore and Setup Swift GitHub Workflows rely on. It never commits the
generated .xcodeproj/.xcworkspace — those are always generator output, regenerated on demand by
xcodegen generate/tuist generate and gitignored by the companion Setup Swift Gitignore.
It is the Swift/Apple equivalent of Setup Android App and
Setup React Native App for the other app-shaped stacks in this catalog; use
Setup macOS App for a macOS-only (SwiftUI or AppKit) desktop app and
Setup Swift Library for a pure SwiftPM library with no app target.
Plugin
Shipped by the iru-swift plugin of the ai-catalog marketplace (install with /plugin install iru-swift@ai-catalog; see Plugins).
Inputs
| Argument | Required | Description | Default |
|---|---|---|---|
|
No |
Pre-resolved parameters passed by an orchestrating skill (e.g. Setup Swift Repository) as
newline-separated |
None — if absent or unrecognized, every field is asked interactively. |
|
Yes (unless supplied via |
Display name, e.g. |
None |
|
Yes (unless supplied via |
Reverse-DNS prefix, e.g. |
None |
|
Yes (unless supplied via |
Multi-select subset of |
None |
|
No |
|
|
|
No |
|
|
|
No |
|
Asked when unset |
|
No |
The iOS deployment target (e.g. |
|
|
No |
|
Asked when unset |
|
No |
|
Asked when unset (defaults toward |
|
Yes (unless supplied via |
Resolved via |
None — user must choose |
|
Yes (unless supplied via |
Recorded in Step 8’s report and each Info.plist’s |
None |
|
No |
Whether the repository is open source; drives the recommended default for |
Asked directly ( |
|
No |
Whether to wire up a SonarQube/SonarCloud scan ( |
|
|
No |
|
Unset (treated as unknown) |
|
No |
|
Unset |
|
No |
|
|
|
No |
|
|
|
No |
|
|
Outputs
-
project.yml(XcodeGen) orProject.swift+Tuist.swift(Tuist), pergenerator, with one target/scheme triple per selected platform. -
Packages/Core/Package.swift(withswift-docc-plugin), a DocC catalog,Models/(Greeting),Services/(GreetingProviding,GreetingService,GreetingError),ViewModels/GreetingViewModel(MVVM / any SwiftUI target) and/orControllers/GreetingController+GreetingViewprotocol (MVC), andTests/CoreTestsat 100% line coverage. -
Per selected platform,
Targets/<Platform>/Sources— SwiftUI<AppName>App.swift+ContentView.swift, or for the iOS target withui: uikitAppDelegate.swift,SceneDelegate.swift,GreetingViewController.swiftandGreetingLayout.swift— plusLaunchOptions.swift;Tests/(Swift Testing:LaunchOptionsTestsand<AppName>Tests, orGreetingViewControllerTests/AppShellTestsfor UIKit); andUITests/<AppName>UITests.swift(XCUITest). -
.swiftlint.yml,.swift-formatand.ui-quality.yml(UI contract settings: accessibility level, directions, themes) at the repository root. -
Per platform test target,
Tests/Support/UIScreenshots.swift(the UI contract capture helper, also compiled into the UI-test target); the UI test writes the sample screen’s captures to.ui-screenshots/screen/<ScreenType>/default--<ltr|rtl>--<light|dark>--<platform-variant>.png(gitignored) and attaches accessibility-audit issues to the.xcresult. -
fastlane/Fastfile, with only the lanesdistribution/signingback — never a lane this skill can’t support. Theplatform :ioslanes (test,build,beta,release) are written only when an iOS/iPadOS target was selected. -
sonar-project.properties, only whensonar!=none— its SwiftLint input issonar.externalIssuesReportPaths=swiftlint-sonar.json, the report the workflows skill’s lint job produces. -
No
.xcodeproj/.xcworkspace— those arexcodegen generate/tuist generateoutput, never written here. -
A report of every resolved input, the mode announced up front, per file whether it was created, updated, replaced or kept as is (with each mismatch listed for a kept file, and how
visibility/cishaped the Sonar recommendation), the Step 7 verification results, the scaffold contract table (targets, schemes, destinations, versions, architecture markers, test/coverage/lint commands, UI-test hooks, UIKit specifics), and explicit warnings (review before build/commit, runiru-setup-swift-gitignore, visionOS runtime needed for its tests, signing/Sonar credentials still needed).
Execution flow
Dependencies
Invokes
None — iru-setup-apple-app is a leaf skill; it does not call any other skill in this catalog. Verification in
Step 7 runs through the iru-gate-runner agent, not another skill.
Invoked by
-
Setup Swift Repository — runs
iru-setup-apple-appfor the app flavor, passing the shared bootstrap inputs (includingplatforms,uiandarchitecture) throughargsso this skill’s own Step 2 questions are skipped.
Related agents
-
iru-gate-runner— Step 7 runsswift test --enable-code-coverage
llvm-cov reportagainstPackages/Core,xcodegen generate(ortuist generate --no-open),xcodebuild testper platform scheme (serialized behind.simulator-test.lock),swiftlint lint --strictandswift format lint --strictthrough this agent so the caller gets a compact pass/fail summary. Missing tools, non-macOS hosts or a missing simulator runtime (typically visionOS, which falls back tobuild-for-testing) are reported as unverified.
Source
SKILL.md on GitHub — the file this page was generated from.