Install
$ agentstack add skill-johnrogers-claude-swift-engineering-grdb ✓ scanned · ✓ verified, works with Claude Code, Cursor, and more.
Security review
✓ PassedNo issues found. Passed automated security review. · v0.1.0 How review works →
- ✓ Prompt-injection patterns
- ✓ Secret / credential exfiltration
- ✓ Dangerous shell & filesystem operations
- ✓ Untrusted network calls
- ✓ Known-malicious package signatures
What it can access
- ✓ Network access No
- ✓ Filesystem access No
- ✓ Shell / process execution No
- ✓ Environment & secrets No
- ✓ Dynamic code execution No
From automated source analysis of v0.1.0. “Used” means the capability is present in the source — more access means more to trust, not that it’s unsafe.
Verified badge
Passed review? Show it. Paste this badge into your README, it links to the public security report.
Reliability & compatibility
Declared compatibility
Compatibility is declared by the source manifest. End-to-end runtime verification is coming, see below.
We're building live execution health for every listing: tool-call success rate, median latency, uptime, and last-checked timestamps, measured, not self-reported. It isn't live yet, so we don't show numbers we can't stand behind.
How agent discovery & health will work →About
GRDB
Direct SQLite access using GRDB.swift - type-safe Swift wrapper with full SQLite power when you need it.
Reference Loading Guide
ALWAYS load reference files if there is even a small chance the content may be required. It's better to have the context than to miss a pattern or make a mistake.
| Reference | Load When | |-----------|-----------| | [Getting Started](references/getting-started.md) | Setting up DatabaseQueue or DatabasePool | | [Queries](references/queries.md) | Writing raw SQL, Record types, type-safe queries | | [Value Observation](references/value-observation.md) | Reactive queries, SwiftUI integration | | [Migrations](references/migrations.md) | DatabaseMigrator, schema evolution | | [Performance](references/performance.md) | EXPLAIN QUERY PLAN, indexing, profiling |
When to Use GRDB vs SQLiteData
| Scenario | Use | |----------|-----| | Type-safe @Table models | SQLiteData | | CloudKit sync needed | SQLiteData | | Complex joins (4+ tables) | GRDB | | Window functions (ROW_NUMBER, RANK) | GRDB | | Performance-critical raw SQL | GRDB | | Reactive queries (ValueObservation) | GRDB |
Core Workflow
- Choose DatabaseQueue (single connection) or DatabasePool (concurrent reads)
- Define migrations with DatabaseMigrator
- Create Record types (Codable, FetchableRecord, PersistableRecord)
- Write queries with raw SQL or QueryInterface
- Use ValueObservation for reactive updates
Requirements
- iOS 13+, macOS 10.15+
- Swift 5.7+
- GRDB.swift 6.0+
Common Mistakes
- Performance assumptions without EXPLAIN PLAN — Assuming your query is fast or slow without checking
EXPLAIN QUERY PLANis guessing. Always profile queries with EXPLAIN before optimizing.
- Missing indexes on WHERE clauses — Queries filtering on non-indexed columns scan the entire table. Index any column used in WHERE, JOIN, or ORDER BY clauses for large tables.
- Improper migration ordering — Running migrations out of order or skipping intermediate versions breaks schema consistency. Always apply migrations sequentially; never jump versions.
- Record conformance shortcuts — Not conforming Record types to
PersistableRecordorFetchableRecordcorrectly leads to silent data loss or deserialization failures. Always implement all required protocols correctly.
- ValueObservation without proper cleanup — Forgetting to cancel ValueObservation when views disappear causes memory leaks and stale data subscriptions. Store the cancellable and clean up in deinit.
Source & license
This open-source skill is cataloged on AgentStack and links to its original source — we do not rehost the code.
- Author: johnrogers
- Source: johnrogers/claude-swift-engineering
- License: MIT
Install and usage instructions live in the source repository linked above.
Reviews
No reviews yet, be the first.
Write a review
Versions
- v0.1.0 Imported from the upstream source.