Skip to content
Back to skills

Swift Coding

ASecurity

Swift coding conventions and project structure. Use when writing or modifying Swift files.

  • 29 stars
  • 0 votes
  • 0 copies
  • 2 views
  • Added September 12, 2026
testingswifttestingbackend

Security analysis

A100/100

Scanned September 12, 2026

npx -y skills add Bogdanp/Ruckus --skill swift-coding --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Swift Coding?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Swift Coding
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/bogdanp-swift-coding/badge)](https://www.skillsdirectory.com/skills/bogdanp-swift-coding)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
description: |
  Swift coding conventions and project structure. Use when writing or modifying
  Swift files.
user-invocable: false
---

# Coding Style

## Project Structure

### Extensions

Place Swift extensions in the appropriate folder:
- `Ruckus/Backend/` — extensions on auto-generated backend types (e.g. `FilesystemEntry`, `File`, `Folder`)
- `Ruckus/Extensions/` — extensions on standard library or framework types (e.g. `URL`)

Name extension files as `TypeName+Feature.swift`.

### Adding or Removing Swift Files

Tuist auto-globs all `.swift` files under `Ruckus/` and `RuckusTests/` — you
do NOT need to manually register new files in `Project.swift`. However, after
adding or removing a file you must regenerate the Xcode project:

    tuist generate --no-open

Without this step, Xcode won't see the new file and the build will fail.

## Logging Style

- Use lower case messages with no punctuation in Logger calls.
- Prefix log messages with `\(#function):` so the call site is visible.
- Example: `Logger.backend.error("\(#function): failed to mark executor step installed: \(error)")`

## Testing

- `Backend.shared` runs Racket completely in-process (embedded via Noise RPC).
  It works in unit tests without mocking — call Backend methods directly.
  Do not inject closures, create protocols, or skip testing Backend-dependent
  code paths.
- After adding new test files, run `tuist generate --no-open` before building
  or running tests. Without this, the Xcode project won't include the new file
  and the tests won't be discovered.

## Post-Change Verification

- After modifying Swift files, always run `swiftlint lint --quiet` on the
  changed files before considering the task complete.

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.