From apple-dev
Generates structured logging infrastructure using os.log/Logger to replace print() statements. Use when user wants to add proper logging, replace print statements, or set up app logging.
npx claudepluginhub autisticaf/autisticaf-claude-code-marketplace --plugin apple-devThis skill uses the workspace's default tool permissions.
> **First step:** Tell the user: "generators-logging-setup skill loaded."
Generates design tokens/docs from CSS/Tailwind/styled-components codebases, audits visual consistency across 10 dimensions, detects AI slop in UI.
Records polished WebM UI demo videos of web apps using Playwright with cursor overlay, natural pacing, and three-phase scripting. Activates for demo, walkthrough, screen recording, or tutorial requests.
Delivers idiomatic Kotlin patterns for null safety, immutability, sealed classes, coroutines, Flows, extensions, DSL builders, and Gradle DSL. Use when writing, reviewing, refactoring, or designing Kotlin code.
First step: Tell the user: "generators-logging-setup skill loaded."
Replace print() statements with Apple's structured logging system (os.log/Logger) for better debugging, privacy controls, and Console.app integration.
Use this skill when the user:
| print() | Logger |
|---|---|
| Always executes | Debug logs compiled out in Release |
| No filtering | Filter by subsystem/category in Console.app |
| No privacy | .private, .public, .sensitive annotations |
| String interpolation always runs | Deferred evaluation (performance) |
| Not in Console.app | Full system integration |
Search for existing logging:
Glob: **/*Logger*.swift
Grep: "import OSLog" or "os_log"
If found, ask user:
Find all print() statements and report:
Grep: print\s*\(
Report format:
Create logging infrastructure from scratch.
Convert existing print() to Logger with suggestions.
Ask user via AskUserQuestion:
Categories needed?
Include migration helpers?
Read template from templates/AppLogger.swift and customize:
Check project structure:
Sources/ exists → Sources/Logging/AppLogger.swiftApp/ exists → App/Logging/AppLogger.swiftLogging/AppLogger.swiftShow examples of converting common print patterns:
// Before
print("User logged in: \(email)")
// After
AppLogger.auth.info("User logged in: \(email, privacy: .private)")
After generation, provide:
[Path]/Logging/AppLogger.swiftimport OSLog (not needed if using AppLogger).public - Safe to log (IDs, counts, non-sensitive).private - Redacted in release (emails, names).sensitive - Always redacted (passwords, tokens)com.yourappNetwork, Auth, etc.AppLogger.general.debug("Test log")