ClaudeNotifier
CLAUDE.md36 starsChanged 10 months agoMITView on GitHub
ClaudeNotifier is a macOS notification app for Claude Code integration. It displays native macOS notifications with Claude's icon, with smart suppression when the user is actively viewing the Claude terminal tab. Clicking a notification focuses the terminal that triggered it. Run make setup after cloning to install git hooks. On each commit: - SwiftFormat auto-formats staged Swift files - SwiftLint checks for violations (strict mode) - Conventional commits validates commit message format Commit messages must follow Conventional Commits: Multi-file Swift…
In this repository4 other files it gives its agents.
- comment-issueSkill
- file-issueSkill
- releaseSkill
- resetSkill
The file
We split this CLAUDE.md into the rules it gives an agent
3 rules. About 0 are common, 1 is distinctive, and 2 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈1
Distinctive · estimate
This author's own choices. Worth a look.
2
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 24
Run make setup after cloning to install git hooks.
- Distinctive: line 29
Commit messages must follow Conventional Commits:
- Very specific: line 88
Never use em dashes (—) or spaced hyphens ( - ) as punctuation.
≈ “Common” is an estimate: at least 1 in 5 of the 12,729 CLAUDE.md files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
CLAUDE.md
This file provides guidance to Claude Code (claude.ai/code) when working with code in this repository.
Project Overview
ClaudeNotifier is a macOS notification app for Claude Code integration. It displays native macOS notifications with Claude's icon, with smart suppression when the user is actively viewing the Claude terminal tab. Clicking a notification focuses the terminal that triggered it.
Build Commands
make build # Compile, bundle as .app, and codesign to build/ClaudeNotifier.app
make install # Build + install to /Applications + create CLI at ~/.local/bin/claude-notifier
make uninstall # Remove app and CLI symlink
make clean # Remove build directory
make icons # Generate icon variants from assets/icon.svg (requires librsvg)
make lint # Run SwiftLint
make format # Run SwiftFormat
make setup # Install pre-commit hooksPre-commit Hooks
Run make setup after cloning to install git hooks. On each commit:
- SwiftFormat auto-formats staged Swift files
- SwiftLint checks for violations (strict mode)
- Conventional commits validates commit message format
Commit messages must follow Conventional Commits:
feat: add new feature
fix: resolve bug
docs: update readme
chore: update dependenciesArchitecture
Multi-file Swift application using AppKit and UserNotifications frameworks.
File structure:
Sources/ClaudeNotifier/
├── main.swift # Entry point - parses args, configures and runs NSApplication
├── Constants.swift # Shared constants (paths, keys, defaults)
├── Models.swift # Data structures (NotificationConfig, ParsedArguments)
├── AppDelegate.swift # NSApplicationDelegate + UNUserNotificationCenterDelegate
├── Setup.swift # Setup command + embedded notify.sh script
├── Doctor.swift # Doctor command - diagnoses installation and permission issues
├── Config.swift # AppConfig model + persistence (load/save config.json)
├── ConfigCommand.swift # Config command - interactive TUI for preferences
├── TUI.swift # Raw terminal input + menu rendering for interactive config
├── Icon.swift # Icon variant utilities (used by ConfigCommand and Doctor)
├── Update.swift # Update command + version check
├── ArgumentParser.swift # CLI flag parsing and help text
└── Utilities.swift # Helpers (exitWithError, terminateApp, focusTerminalSession)Key components:
- Constants: Centralized magic strings (
claudeDirectory,sessionIdKey, etc.) - Models:
NotificationConfigandParsedArgumentsdata structures - AppDelegate: Handles notification display, authorization, and click responses
- Setup: Embedded
notify.shscript + functions to configure~/.claude/settings.jsonhooks - Doctor: Checks installation, hooks, permissions, and PATH configuration
- Config:
AppConfigmodel with icon/sound fields, JSON persistence to~/Library/Application Support/ClaudeNotifier/config.json - ConfigCommand: Interactive TUI for configuring icon color and notification sound
- TUI: Raw terminal mode handling, arrow key navigation, and menu rendering
- Icon:
IconVariantenum,getCurrentVariant(),setVariant(), and helper functions for icon switching - Update: Version check via GitHub API, brew upgrade integration, doctor version check
- ArgumentParser: Parses
-t,-s,-m,-iflags andsetup/doctor/config/update/helpsubcommands - Utilities:
exitWithError(),terminateApp(),focusTerminalSession(),TerminalTypeenum
Entry flow: Parse args → configure NSApplication → show notification (if -m provided) → handle notification click → focus terminal → exit
CLI Usage
claude-notifier -m "Message" -t "Title" -s "Subtitle"
claude-notifier -m "Message" -i "$ITERM_SESSION_ID" # With session ID for focus-on-click
claude-notifier setup # Auto-configure Claude Code hooks
claude-notifier doctor # Diagnose installation and permission issues
claude-notifier config # Configure preferences (icon, sound) interactively
claude-notifier update # Check for updates and upgrade via HomebrewWriting Style
- Never use em dashes (
—) or spaced hyphens (-) as punctuation. Use commas, colons, or parentheses instead.
Technical Notes
- Requires macOS 11.0+
- Uses native frameworks: AppKit, UserNotifications
- Makefile uses
swiftcdirectly (not full SPM build) for the app bundle - App is ad-hoc codesigned during build
- Runs as LSUIElement (no dock icon)
- Requires Automation permission for iTerm2 and Terminal.app (prompted on first notification click)
- IDE editors (VS Code, Cursor, Windsurf, Zed) use Launch Services for focus — no Automation permission needed
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

