develop-swift
Skill0 starsChanged 2 months agoApache-2.0View on GitHub
Apply a Swift project's own conventions, build commands, and test commands while writing or changing Swift code in a Swift package or an Xcode project, and verify the change with `swift build`, `swift test`, or `xcodebuild`. Use it whenever a task writes, changes, or tests Swift code, such as adding a function or type to a package with a Package.swift, fixing a failing XCTest or Swift Testing test, or resolving a Swift 6 concurrency diagnostic in an .xcodeproj or .xcworkspace, even when the request does not mention conventions or verification. Do not use it for a project without `.swift` files.
1 other project uses a version of this.
Adopted by
Most recently taken up by
- juju-w/safa-runtimetheir own version, first seen Aug 18, 2026
Other versions1 project uses a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 1
- juju-w/safa-runtime★ 1same name
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository37 other files it gives its agents.
- AGENTS.mdAGENTS.md
- analyze-codebaseSkill
- analyze-projectSkill
- propose-improvementsSkill
- retrospect-workSkill
- triage-issuesSkill
- write-docsSkill
- debug-codeSkill
- refactor-codeSkill
- resolve-defectSkill
- write-testsSkill
- develop-minecraft-fabricSkill
- develop-minecraft-forgeSkill
- audit-workflow-enforcementSkill
- bootstrap-projectSkill
- develop-dartSkill
- develop-goSkill
- develop-javaSkill
- develop-kotlinSkill
- develop-typescriptSkill
- update-dependenciesSkill
- develop-android-composeSkill
- develop-compose-multiplatformSkill
- develop-flutterSkill
- develop-iosSkill
- develop-kotlin-multiplatformSkill
- develop-react-nativeSkill
- create-issueSkill
- create-prSkill
- deliver-changeSkill
- fix-prSkill
- implement-issueSkill
- improve-projectSkill
- merge-prSkill
- plan-issueSkill
- review-prSkill
- develop-reactSkill
The file
Show its rules and text
We split this skill into the rules it gives an agent
15 rules. About 0 are common, 6 are distinctive, and 9 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈6
Distinctive · estimate
This author's own choices. Worth a look.
9
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 13
Verify the change with the project's build, tests, and configured lint or format checks, and record each command and result.
- Distinctive: line 16
Keep exactly one item in progress.
- Very specific: line 31
Stop and say that this skill does not apply when the repository has no .swift files.
- Very specific: line 40
Read the // swift-tools-version: line on the first line of Package.swift, the platforms list, and the language mode from swiftLanguageModes …
- Very specific: line 57
Prefer that entry point, because it carries the project's scheme, destination, and flags.
- Very specific: line 68
Follow the target and folder layout already in use.
- Very specific: line 71
Use a value type (struct or enum) by default.
- Very specific: line 73
Prefer let over var.
- Very specific: line 80
Use async and await and actors for concurrent work.
- Distinctive: line 84
Write tests with the framework the target already uses, XCTest or Swift Testing.
- Distinctive: line 86
Follow the existing SwiftLint and swift-format configuration, and do not disable a rule to make a check pass.
- Very specific: line 88
Add a package dependency in Package.swift and run swift package resolve so Package.resolved changes in the same change.
- Distinctive: line 94
Run the project's entry point for each check when it has one.
- Distinctive: line 105
When the machine lacks Xcode, the Swift toolchain, or the simulator runtime the destination needs, report the check as not run, with the …
- Very specific: line 120
Use plain, active, evidence-backed prose in the handoff.
≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Develop Swift
Todo List
- in progress: Confirm the Swift package or Xcode project, its tools version, platforms, and language mode, and the project's own commands.
- Make the requested Swift change following the project's conventions.
- Verify the change with the project's build, tests, and configured lint or format checks, and record each command and result.
- Complete the list only when every verification command has a recorded result; hand off the commands, results, and any skipped check.
Keep exactly one item in progress. Mark an item complete only when its evidence exists. Use the host's native Todo List, or keep the same list as a Markdown checklist when no native list is available.
Scope
This skill is a technology skill in the language category. It gives Swift
knowledge to the task that is already running. It does not choose what to
change, and it creates no Issue, Pull Request, branch, or release. When the
task belongs to a workflow skill such as implement-issue, write-tests, or
debug-code, that skill keeps ownership of the plan, the commits, and the
handoff; this skill supplies the Swift commands and conventions. A framework
skill, such as one for iOS, can build on this skill for the language, package,
and build rules.
Stop and say that this skill does not apply when the repository has no
.swift files.
1. Discover the project
- Find the build. A Swift package has a
Package.swift; an Xcode project has an.xcodeproj, and an.xcworkspacewhen it combines projects or packages. A repository can have both, such as an app project that depends on a local package. - Read the
// swift-tools-version:line on the first line ofPackage.swift, theplatformslist, and the language mode fromswiftLanguageModes(tools version 6.0 and later) orswiftLanguageVersions(earlier), plus any per-targetswiftSettingssuch as.swiftLanguageMode(.v5). A package with tools version 6.0 and no language mode setting builds in the Swift 6 mode, which makes data-race checks errors. Read the default actor isolation too:.defaultIsolation(MainActor.self)inPackage.swift, or theSWIFT_DEFAULT_ACTOR_ISOLATIONbuild setting, makes unannotated code run on the main actor and changes what needsSendableornonisolated. In an Xcode project, read theSWIFT_VERSION,SWIFT_STRICT_CONCURRENCY, andSWIFT_DEFAULT_ACTOR_ISOLATIONbuild settings. Do not change the tools version, the platforms, the language mode, or the default actor isolation unless the task asks for it, because each change can break every caller and every target. - Find the project's own entry point before using raw
swiftorxcodebuildcommands: aMakefiletarget, amise.tomltask, a fastlane lane infastlane/Fastfile, or scripts named in the contributor documentation. Prefer that entry point, because it carries the project's scheme, destination, and flags; a rawswift testcan pass while the project's own check fails. - Find the checks the project configures:
.swiftlint.ymlfor SwiftLint and.swift-formatfor swift-format, and the commands its CI workflows run. Do not add a linter or formatter the project does not use. - Find the test framework from the existing tests:
import XCTestwithXCTestCasesubclasses, orimport Testingwith@Testand#expect.
2. Change the code
- Follow the target and folder layout already in use. Keep access control
minimal: leave declarations
internalby default, and mark thempubliconly when they are part of the module's API. - Use a value type (
structorenum) by default. Use aclassonly when the value needs identity or shared mutable state that callers must observe. - Prefer
letovervar. - Handle an optional with
guard letorif let. Do not use a force unwrap (!) ortry!unless a comment states why it cannot fail. - Throw an error type the caller can match, such as an
enumthat conforms toError, or typedthrows(SomeError)when the project already uses it. Do not swallow an error with an emptycatchor withtry?when the caller needs to know about the failure. - Use
asyncandawaitand actors for concurrent work. KeepSendableconformance and@MainActorisolation correct instead of silencing a diagnostic; do not add@unchecked Sendableornonisolated(unsafe)without a comment that states why the access is safe. - Write tests with the framework the target already uses, XCTest or Swift Testing. Do not mix a second framework into a test target that uses one.
- Follow the existing SwiftLint and swift-format configuration, and do not disable a rule to make a check pass.
- Add a package dependency in
Package.swiftand runswift package resolvesoPackage.resolvedchanges in the same change. Do not runswift package updateunless the task asks for newer versions.
3. Verify
Run the project's entry point for each check when it has one. Otherwise run:
| Check | Command | Pass condition |
| Package build | swift build | Exits 0 |
| Package test | swift test | Exits 0 |
| Xcode schemes | xcodebuild -list with -project <name>.xcodeproj or -workspace <name>.xcworkspace | Lists the scheme to test |
| Xcode test | xcodebuild -project <name>.xcodeproj or -workspace <name>.xcworkspace, then -scheme <scheme> -destination '<destination>' test, such as -destination 'platform=macOS' or -destination 'platform=iOS Simulator,name=<device>' from xcrun simctl list devices available | Exits 0 |
| Lint | swiftlint lint when the project has .swiftlint.yml | Exits 0 and reports no new violation |
| Format | swift format lint --recursive . when the project has .swift-format | Prints no finding |
When the machine lacks Xcode, the Swift toolchain, or the simulator runtime the destination needs, report the check as not run, with the error, instead of claiming it passed. Fix a failure the change caused before handoff. Report a failure the change did not cause as an existing failure, with the command and its output, instead of fixing unrelated code.
Handoff
Report each verification command, its exit status, and its result. Name every check you skipped and why, such as a missing Xcode or simulator runtime. When a workflow skill owns the task, return these results to it; that skill owns the next phase.
Writing quality
Use plain, active, evidence-backed prose in the handoff. Choose the plain word
over an inflated or Latinate one: write use rather than utilize and is
rather than serves as. Name the file, command, or output behind every claim
about the project.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

