write-swift
An agent skill by emilkowalski, from emilkowalski/skills. Tags: code-quality, concurrency, development, performance, swift.
What it does
How to write modern Swift well — modeling with value types, Swift 6 data-race safety and approachable concurrency (@concurrent, main-actor-by-default, actors, task groups), protocols and generics (some vs any), API design, performance and ARC, Swift Testing, macros, and the modern language features agents don't know about yet. Use when writing, reviewing, or migrating Swift, or when a concurrency error, a hang, a data race, a retain cycle, or a performance problem needs fixing.
Install
With the skills CLI, which installs into Claude Code, Codex, Cursor and other agents:
npx skills add emilkowalski/skills --skill write-swift
Or copy the skill folder into Claude Code's skills directory by hand (~/.claude/skills for every project, or .claude/skills inside one):
git clone --depth 1 https://github.com/emilkowalski/skills
cp -r skills/skills/write-swift ~/.claude/skills/write-swift
Safety box score
Grade A, minimal risk: 0 of 100 risk points, rated 2026-10-20. The grade rates what the skill and its scripts can reach on the machine of whoever installs it, across eight categories from shell execution to secrets access. How the score works.
This skill is a pure Markdown guidance doc for writing and reviewing Swift; it ships no scripts, binaries, or networked tooling. It does not touch files, secrets, or system settings, and the only notable caution is that some advice is version-specific and references unreleased Swift 6.4 features.
| Category | Level | Why |
|---|---|---|
| Code & shell execution | 0 (none) | `SKILL.md` is prose only; there are no shell commands, scripts, code generators, or other executable payloads. |
| Network access | 0 (none) | No URLs are fetched and nothing in the skill sends data to remote hosts; it is offline documentation only. |
| Filesystem reach | 0 (none) | The skill does not read, write, or delete files; it only describes Swift patterns and APIs. |
| Secrets & credentials | 0 (none) | There is no request to access tokens, keychains, `.env` files, browser sessions, or other secrets. |
| Privilege & persistence | 0 (none) | No sudo, service installs, shell startup edits, or OS/git settings changes are present. |
| Instruction hijack surface | 0 (none) | The file contains ordinary agent-facing guidance like an initial response format, but no prompt-injection payloads, hidden text, or instructions to ignore higher-priority rules. |
| Irreversible actions | 0 (none) | It does not push, publish, post, pay, deploy, or delete anything; it is advisory only. |
| Transparency | 0 (none) | All shipped content is readable Markdown; there are no binaries, base64 blobs, downloaded installers, or unpinned external dependencies. |
Before installing
- No code to audit here: the skill is documentation-only, so there is nothing executable to vet.
- If your project is on Swift 6.3 or earlier, note that some guidance references Swift 6.4-only or unreleased features before relying on it.
Rated 2026-10-20 by an automated review of 1 file from the skill's repository.
Source
- Repository
- emilkowalski/skills (all skills from this repository)
- Path
- skills/write-swift/SKILL.md
- Branch
- main
- Updated
- 2026-09-22
Related skills
- expo-migrate-module — Framework (OSS). Migrate an existing Apple/Swift Expo native module from the Expo Modules API 1.0 definition DSL to the 2.0 macro API (sometimes called v2).
- deslop — Remove AI-generated code slop and clean up code style
- expo-module — Framework (OSS). Guide for creating and writing Expo native modules and views using the Expo Modules API (Swift, Kotlin, TypeScript).
- principle-laziness-protocol — Apply when refactoring, evaluating diff size, or tempted to add abstractions, layers, or signal threading.
- principle-separate-before-serializing-shared-state — Apply when concurrent actors might write to the same file, branch, key, or state object.
- principle-subtract-before-you-add — Apply when sequencing an addition, refactor, or rewrite. Remove dead code, redundant validators, and stub references first, then build on the simpler base.