theblixguy

Swift Bylaws — Development skill for Claude Code

Development community

Architectural linting for Swift developers and coding agents.

How to install Swift Bylaws

This entry records only its repository, not the path inside it, so there is no exact command to give. Open theblixguy/swift-bylaws and copy the folder into ~/.claude/skills/, or the file into ~/.claude/agents/.

What Swift Bylaws does

Architectural linting for Swift developers and coding agents.

Alternatives in Development

  • Example Plugin — Reference implementation for plugin developers 14k ★
  • Triage PRs — Classify all open PRs by module, review state, scope, and architectural impact — produces a prioritized triage 12.6k ★
  • Claude Reviews Claude — Claude reads its own source code — 17-chapter architectural deep-dive into Claude Code v2.1.88. EN/ZH bilingua 1.3k ★

README

Bylaws

Bylaws is an architectural linter for Swift, built for developers and coding agents.

[![Swift versions][Swift versions badge]][Swift Package Index] [![Platforms][Platforms badge]][Swift Package Index] [![CI][CI badge]][CI]

![Rules in Xcode and a violation in VS Code](.github/images/bylaws-editors.png)

Read the [documentation] for guides and the API reference.

Contents

Why Bylaws?

Every project has rules that the compiler cannot enforce. Some might concern individual declarations or API use, such as naming conventions, required protocols or which parts of the codebase can call an API. Others describe the wider project through its folder layout or the dependencies allowed between different parts of the codebase.

AI coding agents can help a team move faster, but the changes they produce can also break project rules and be difficult to review line by line. Skill files and `AGENTS.md` can provide useful context, but they cannot ensure that every instruction is applied consistently.

With Bylaws, you can write your project rules using familiar Swift APIs and run them through Swift Testing or the CLI. If a change breaks a rule, Bylaws reports the relevant file and line so both developers and coding agents know what to fix.

What a rule can check

A rule can inspect declarations, function calls and other Swift syntax. It can check where files and types belong, compare a `Package.swift` manifest with the imports in its source, find dependency cycles or restrict references between files, folders or modules.

Most rules only need access to the source code and project files, so the CLI can run them without a build an