一键导入
swift
Swift development: concurrency patterns, async/await, actors, testing with XCTest and Swift Testing framework.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
菜单
Swift development: concurrency patterns, async/await, actors, testing with XCTest and Swift Testing framework.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
Planning lifecycle: specs, requirements, pre-plan ambiguity resolution, file-backed plans, plan validation, pause/resume, session handoff.
Fresh-subagent-per-task execution with two-stage review gates.
Comprehensive 3-wave review of all repo source files, producing a prioritized issue backlog.
Business operations: strategy, technology, growth, competitive intelligence, support, finance, HR, legal, operations, sales, productivity, product management.
Customer support workflows — ticket triage, response drafting, knowledge base articles, escalation handling, customer research. Use when triaging support tickets, drafting customer responses, creating KB articles, managing escalations, or researching customer context.
Finance and accounting: journal entries, reconciliation, variance analysis, financial statements, audit support, month-end close, SOX testing.
| name | swift |
| description | Swift development: concurrency patterns, async/await, actors, testing with XCTest and Swift Testing framework. |
| user-invocable | false |
| context | fork |
| agent | swift-general-engineer |
| routing | {"triggers":["swift concurrency","swift async await","Swift Actor","Swift Task group","swift testing","XCTest","Swift Testing framework","async test swift"],"category":"swift","pairs_with":["test-driven-development","code-linting"]} |
Swift concurrency and testing: async/await, Actors, TaskGroups, Sendable, structured concurrency, XCTest, Swift Testing framework, and async test patterns.
| Signal | Reference | Size |
|---|---|---|
| async/await, Task, Sendable | references/fundamentals.md | ~20 lines |
| Actor, @MainActor, nonisolated | references/actor-isolation.md | ~20 lines |
| TaskGroup, AsyncSequence, AsyncStream, cancellation | references/task-patterns.md | ~20 lines |
| Failure modes, common mistakes | references/preferred-patterns.md | ~20 lines |
| concurrency overview, structured concurrency patterns | references/swift-concurrency.md | ~30 lines |
| XCTest, Swift Testing, test doubles, async tests, UI tests | references/swift-testing.md | ~250 lines |
Load greedily. If the user's question touches any signal keyword, load the matching reference before responding. Multiple signals matching = load all matching references.
TaskGroup over loose Task { } whenever possible; structured tasks propagate cancellation and errors automatically.-strict-concurrency=complete) and resolve all warnings before they become errors in Swift 6.Task stored in a property should have a corresponding cancellation path.testFetchUser_withExpiredToken_throwsAuthError is better than testFetch2.@Test and #expect when targeting Swift 5.9+; fall back to XCTest for older targets or UI tests.Determine what kind of Swift work is needed:
| Request type | Load references | Action |
|---|---|---|
| Concurrency patterns | fundamentals, actor-isolation, task-patterns | Pattern guidance |
| Concurrency mistakes | preferred-patterns | Failure mode detection |
| Write tests | swift-testing | Test authoring |
| Async test patterns | swift-testing + fundamentals | Async test guidance |
| Full concurrency review | swift-concurrency + all concurrency refs | Full review pass |
Gate: Request classified and relevant references loaded.
Apply loaded reference knowledge to the user's code or question.
For concurrency work:
For testing work:
@Test, #expect) for new code on Swift 5.9+@dataProvider-style parameterized tests with arguments:Gate: Specific, reference-backed feedback or code provided.
Run the test suite and confirm:
swift test --enable-code-coverage
swift build
Gate: All tests pass. Build succeeds with strict concurrency checking.