Agent skill

Sake Macro Development

by kattouf in kattouf/Sake

A skill your agent uses when modifying the @CommandGroup macro in SakeMacros target — SwiftSyntax ExtensionMacro, code generation patterns, testing with assertMacroExpansion.

MITAuto-check passedMobile

Install Sake Macro Development

skills CLI
$ npx skills add kattouf/Sake --skill sake-macro-development -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install kattouf/Sake sake-macro-development --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/kattouf/Sake.git skills-src && mkdir -p .claude/skills && cp -r skills-src/.claude/skills/sake-macro-development .claude/skills/sake-macro-development && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
sake-macro-development
GitHub stars
116
Token cost
~844 tokens
SKILL.md length
140 words
Files
1
Skills in repo
8
Repo updated
First seen
Licence
MIT

At a glance

A skill your agent uses when modifying the @CommandGroup macro in SakeMacros target — SwiftSyntax ExtensionMacro, code generation patterns, testing with assertMacroExpansion.

  • Works in 2 steps: CommandGroup protocol conformance → A commands computed property —…
  • Modifying the @CommandGroup macro in SakeMacros target — SwiftSyntax ExtensionMacro
  • SKILL.md covers What the Macro Does, Inclusion Criteria, Implementation and SwiftSyntax Patterns Used, plus 2 more sections
  • Instructions only: no scripts, shell commands, URLs or credentials in SKILL.md

What it does

Sake Macro Development is an agent skill from kattouf/Sake. Use when modifying the @CommandGroup macro in SakeMacros target — SwiftSyntax ExtensionMacro, code generation patterns, testing with assertMacroExpansion.

Its SKILL.md is about 840 tokens, which your agent loads only when the skill is triggered. It is a single SKILL.md file with no bundled scripts.

It sits in Mobile, covering iOS development. It works with Bash. The repository describes itself as: 🍶 Swift-based utility for managing project commands, inspired by Make. The licence is MIT.

When your agent uses it

  • Modifying the @CommandGroup macro in SakeMacros target — SwiftSyntax ExtensionMacro
  • Code generation patterns
  • Testing with assertMacroExpansion

Example prompts

  • “/sake-macro-development”

Workflow steps

2 steps, taken from the first numbered list in SKILL.md.

  1. CommandGroup protocol conformance
  2. A commands computed property — dictionary of all public static Command vars

What it can do on your machine

Read from SKILL.md and the folder at commit 80a3e98. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    No scripts in the folder and no shell commands in SKILL.md (its code samples are swift).

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    No URLs in SKILL.md.

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

Sake Macro Development loads about 844 tokens when it runs. Until then it costs about 44 tokens; SKILL.md has 140 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~44
When it runs · the whole SKILL.md, loaded when a task matches
~844

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.

SKILL.md

The full file from kattouf/Sake at commit 80a3e98, republished under its MIT licence (© kattouf). 140 words, ~844 tokens.

Download SKILL.mdSave it as .claude/skills/sake-macro-development/SKILL.md (or your agent's skills folder).
name
sake-macro-development
description
Use when modifying the @CommandGroup macro in SakeMacros target — SwiftSyntax ExtensionMacro, code generation patterns, testing with assertMacroExpansion.

Sake Macro Development

Reference for working on the @CommandGroup Swift macro.

What the Macro Does

@CommandGroup is an ExtensionMacro that generates:

  1. CommandGroup protocol conformance
  2. A commands computed property — dictionary of all public static Command vars
swift
// Input
@CommandGroup
struct MyCommands {
    public static var hello: Command { ... }
    public static var bye: Sake.Command { ... }
    static var internal: Command { ... }       // excluded: not public
    private var foo: Command { ... }           // excluded: not public, not static
}

// Generated
extension MyCommands: Sake.CommandGroup {
    static var commands: [String: Sake.Command] {
        ["hello": Self.hello, "bye": Self.bye]
    }
}

Inclusion Criteria

A property is included in commands only if ALL of:

  • Has public modifier
  • Has static modifier
  • Type annotation is exactly Command or Sake.Command

Typealiases, inferred types, or other spellings are NOT detected.

Implementation

File: Sources/SakeMacros/SakeAppMacro.swift

swift
public struct CommandGroupMacro: ExtensionMacro {
    public static func expansion(...) throws -> [ExtensionDeclSyntax] {
        // 1. Filter members: public + static
        // 2. Check type annotation: Command or Sake.Command
        // 3. Extract variable names
        // 4. Generate dictionary literal
        // 5. Return extension with CommandGroup conformance
    }
}

Plugin registration: Sources/SakeMacros/Plugin.swift

SwiftSyntax Patterns Used

  • declaration.memberBlock.members — iterate struct members
  • .compactMap { $0.decl.as(VariableDeclSyntax.self) } — get variable declarations
  • $0.modifiers.map(\.name.text) — check access modifiers
  • binding.typeAnnotation?.type.as(IdentifierTypeSyntax.self) — simple type (Command)
  • binding.typeAnnotation?.type.as(MemberTypeSyntax.self) — qualified type (Sake.Command)
  • binding.pattern.as(IdentifierPatternSyntax.self)?.identifier.text — variable name
  • ExtensionDeclSyntax("""...""") — string interpolation for generating syntax

Testing

File: Tests/SakeMacrosTests/SakeAppMacroTests.swift

Uses SwiftSyntaxMacrosTestSupport:

swift
import SakeMacros
import SwiftSyntaxMacrosTestSupport

assertMacroExpansion(
    """
    @CommandGroup
    struct MyCommands {
        public static var hello: Command { ... }
    }
    """,
    expandedSource: """
    struct MyCommands {
        public static var hello: Command { ... }
    }

    extension MyCommands: Sake.CommandGroup {
        static var commands: [String: Sake.Command] {
            ["hello": Self.hello]
        }
    }
    """,
    macros: ["CommandGroup": CommandGroupMacro.self],
)

Key test cases:

  • Multiple commands with mixed visibility (public, private, static, non-static)
  • Both Command and Sake.Command type annotations
  • Zero commands → generates [:]

Dependencies

swift
// Package.swift
.macro(name: "SakeMacros", dependencies: [
    .product(name: "SwiftSyntaxMacros", package: "swift-syntax"),
    .product(name: "SwiftCompilerPlugin", package: "swift-syntax"),
])

swift-syntax version: 602.0.0+

© kattouf, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

Just SKILL.md in .claude/skills/sake-macro-development of kattouf/Sake.

Open the folder on GitHubat commit 80a3e98

Compare with similar skills

Sake Macro Development next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

Sake Macro Development compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Sake Macro Development this skillkattouf/Sake116—~844Automated safety check: PassMIT
UI Automation Workflowsconorluddy/xclaude-plugin183—~2.2kAutomated safety check: PassMIT
Swiftui Protwostraws/SwiftUI-Agent-Skill5.1k2 repos~1.5kAutomated safety check: PassMIT
Swiftui UI PatternsAFK-surf/OpenBridge4304 repos~887Automated safety check: PassMIT
Swiftui Performance Auditharperreed/dotfiles3348 repos~1.4kAutomated safety check: PassNone
Hig Project Contextraintree-technology/hig-doctor1435 repos~1.2kAutomated safety check: PassMIT

Similar skills

  • UI Automation Workflows

    conorluddy/xclaude-plugin

    Accessibility-first UI automation using IDB. An agent skill from conorluddy/xclaude-plugin.

    183 GitHub stars~2.2k tokensUpdated 26 days ago
    Frontend & DesignAuto-check passed
  • Swiftui Pro

    twostraws/SwiftUI-Agent-Skill

    Comprehensively reviews SwiftUI code for best practices on modern APIs, maintainability, and performance.

    5.1k GitHub starsUsed in 2 repos~1.5k tokens
    MobileAuto-check passed
  • Swiftui UI Patterns

    AFK-surf/OpenBridge

    Best practices and example-driven guidance for building SwiftUI views and components.

    430 GitHub starsUsed in 4 repos~887 tokens
    MobileAuto-check passed
  • Swiftui Performance Audit

    harperreed/dotfiles

    Audit and improve SwiftUI runtime performance from code review and architecture.

    334 GitHub starsUsed in 8 repos~1.4k tokens
    MobileAuto-check passed
  • Hig Project Context

    raintree-technology/hig-doctor

    Create or update a shared Apple design context document that other HIG skills use to tailor guidance.

    143 GitHub starsUsed in 5 repos~1.2k tokens
    MobileAuto-check passed
  • Hig Components Content

    raintree-technology/hig-doctor

    Apple Human Interface Guidelines for content display components.

    143 GitHub starsUsed in 5 repos~1.3k tokens
    MobileAuto-check passed

More from kattouf/Sake

All 8 skills in this repo
  • Sake CI Release

    kattouf/Sake

    A skill your agent uses when working on CI workflows, GitHub Actions, release process, changelog generation (git-cliff), or dependabot configuration.

    116 GitHub stars~731 tokensUpdated 6 mo ago
    Auto-check passed
  • A skill your agent uses when working on SakeCLI or SakeCLILibrary targets — CLI entry point, config resolution, SakeAppManager build/run lifecycle, error handling, shell execution.

    116 GitHub stars~1.1k tokensUpdated 6 mo ago
    Auto-check passed
  • A skill your agent uses when writing or modifying Sake commands, CommandGroups, SakeApp files, or SakeApp/ directory code.

    116 GitHub stars~1.1k tokensUpdated 6 mo ago
    Auto-check passed
  • Sake Config System

    kattouf/Sake

    A skill your agent uses when working on Sake configuration — .sake.yml, environment variables, CLI options, ConfigManager, ConfigResolver, or adding new config options.

    116 GitHub stars~687 tokensUpdated 6 mo ago
    Auto-check passed
  • Sake Docs

    kattouf/Sake

    A skill your agent uses when writing or updating Sake documentation — VitePress site structure, existing pages, how to add new docs, documentation conventions.

    116 GitHub stars~778 tokensUpdated 6 mo ago
    Auto-check passed
  • Sake Testing

    kattouf/Sake

    A skill your agent uses when writing or running tests for the Sake project — unit tests, macro expansion tests, integration tests, test helpers, and CI test commands.

    116 GitHub stars~743 tokensUpdated 6 mo ago
    Auto-check passed

Works with

Categories

Questions about Sake Macro Development

What does Sake Macro Development do?

A skill your agent uses when modifying the @CommandGroup macro in SakeMacros target — SwiftSyntax ExtensionMacro, code generation patterns, testing with assertMacroExpansion. Sake Macro Development is an agent skill from kattouf/Sake. Use when modifying the @CommandGroup macro in SakeMacros target — SwiftSyntax ExtensionMacro, code generation patterns, testing with assertMacroExpansion.

When should I use Sake Macro Development?

Sake Macro Development fits situations like: modifying the @CommandGroup macro in SakeMacros target — SwiftSyntax ExtensionMacro; code generation patterns; testing with assertMacroExpansion.

How do I install Sake Macro Development in Claude Code?

Run `npx skills add kattouf/Sake --skill sake-macro-development -a claude-code`. Or copy the skill folder (.claude/skills/sake-macro-development in kattouf/Sake) into .claude/skills/sake-macro-development in your project. Claude Code loads it when a task matches its description.

How do I install Sake Macro Development in Codex?

Run `npx skills add kattouf/Sake --skill sake-macro-development -a codex`. Or copy the skill folder (.claude/skills/sake-macro-development in kattouf/Sake) into .agents/skills/sake-macro-development in your project. Codex loads it when a task matches its description.

Can I use Sake Macro Development in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add kattouf/Sake --skill sake-macro-development -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/sake-macro-development, .gemini/skills/sake-macro-development, .github/skills/sake-macro-development and .opencode/skills/sake-macro-development in your project.

What does Sake Macro Development need to run?

SKILL.md names no scripts, command-line tools or credentials: Sake Macro Development is instructions for the agent only.

Does Sake Macro Development access the network?

SKILL.md contains no URLs. Any network use would come from the scripts or tools the agent runs. This is read from the text; nothing was executed.

Is Sake Macro Development safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.

What licence does Sake Macro Development use?

Sake Macro Development is published under the MIT licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Sake Macro Development use?

About 844 tokens (SKILL.md is roughly 3.4k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.

What are the alternatives to Sake Macro Development?

Skills that share tags, products or a category with Sake Macro Development: UI Automation Workflows (conorluddy/xclaude-plugin, 183 stars), Swiftui Pro (twostraws/SwiftUI-Agent-Skill, 5.1k stars), Swiftui UI Patterns (AFK-surf/OpenBridge, 430 stars) and Swiftui Performance Audit (harperreed/dotfiles, 334 stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Sake Macro Development?

kattouf (a GitHub user) maintains it in kattouf/Sake, which has 116 GitHub stars. The repository holds 8 skills in this directory. The repository was last updated on April 5, 2026.

Source: kattouf/Sake on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.