一键导入
setup
Interactive setup wizard for the agent-notifications plugin. Detects the terminal, walks through notification preferences, and writes the config file.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
菜单
Interactive setup wizard for the agent-notifications plugin. Detects the terminal, walks through notification preferences, and writes the config file.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
基于 SOC 职业分类
| name | setup |
| description | Interactive setup wizard for the agent-notifications plugin. Detects the terminal, walks through notification preferences, and writes the config file. |
| disable-model-invocation | true |
Interactive wizard to configure the agent-notifications plugin. The config file lives at ~/.claude/agent-notifications/config.json. Present each step in sequence, asking one question at a time.
Read ~/.claude/agent-notifications/config.json if it exists.
Run the following to identify the terminal environment:
echo "TERM_PROGRAM=$TERM_PROGRAM KITTY_WINDOW_ID=$KITTY_WINDOW_ID WEZTERM_EXECUTABLE=$WEZTERM_EXECUTABLE ITERM_SESSION_ID=$ITERM_SESSION_ID VSCODE_GIT_IPC_HANDLE=$VSCODE_GIT_IPC_HANDLE"
Terminal detection mapping:
| Environment Variable / Value | Terminal | Notification Method |
|---|---|---|
TERM_PROGRAM=ghostty | Ghostty | OSC 777 (native) |
WEZTERM_EXECUTABLE set | WezTerm | OSC 777 (native) |
TERM_PROGRAM=iTerm.app or ITERM_SESSION_ID set | iTerm2 | OSC 9 (native) |
KITTY_WINDOW_ID set | Kitty | OSC 99 (native) |
TERM_PROGRAM=vscode or VSCODE_GIT_IPC_HANDLE set | VS Code | terminal-notifier (fallback) |
TERM_PROGRAM=Apple_Terminal | Terminal.app | terminal-notifier (fallback) |
TERM_PROGRAM=WarpTerminal | Warp | terminal-notifier (fallback) |
TERM_PROGRAM=Hyper | Hyper | terminal-notifier (fallback) |
Report the detected terminal and whether it supports native OSC notifications. Native OSC terminals work across all tabs and windows without extra dependencies.
For fallback terminals, check if terminal-notifier is installed:
which terminal-notifier
If missing, suggest brew install terminal-notifier.
Skip this step for native OSC terminals — bundle ID is irrelevant for them.
For fallback terminals, the bundle ID controls which app activates when clicking a notification. Auto-detect it:
osascript -e 'id of app "AppName"'
Common bundle IDs:
| Terminal | Bundle ID |
|---|---|
| Ghostty | com.mitchellh.ghostty |
| iTerm2 | com.googlecode.iterm2 |
| Terminal.app | com.apple.Terminal |
| VS Code | com.microsoft.VSCode |
| Warp | dev.warp.Warp-Stable |
| Hyper | co.zeit.hyper |
For other terminals (e.g., Cursor, Alacritty), detect the bundle ID with osascript -e 'id of app "AppName"'.
Ask the user about each setting one at a time, offering sensible defaults:
Notification types — Enable/disable individual events. All enabled by default:
question — Claude asks a questionplanReady — Claude finishes a planpermission — Claude needs tool permissiontaskCompleted — Claude finishes respondingMessage detail level — "full" (context + branch + project) or "minimal" (event + project only). Default: "full".
Sounds (fallback terminals only) — macOS system sounds used by terminal-notifier. Default: Blow for most events, Glass for taskCompleted. List available sounds with ls /System/Library/Sounds/ | sed 's/.aiff//'. Preview with afplay /System/Library/Sounds/Glass.aiff.
Frontmost detection (fallback terminals only) — When skipFrontmostDetection is false (default), notifications are suppressed if the terminal app is focused. Ask whether to always notify regardless.
Skip settings that don't apply to the detected terminal (e.g., sounds and frontmost detection for OSC terminal users).
Assemble the final config JSON:
{
"sounds": {
"question": "Blow",
"planReady": "Blow",
"permission": "Blow",
"taskCompleted": "Glass"
},
"notifications": {
"question": true,
"planReady": true,
"permission": true,
"taskCompleted": true
},
"terminal": {
"skipFrontmostDetection": false,
"bundleId": "<detected>"
},
"messageDetail": "full"
}
Show the assembled config to the user for confirmation before writing. Create the directory if needed (~/.claude/agent-notifications/), then write to ~/.claude/agent-notifications/config.json.
After writing, confirm success and note that the plugin picks up the new config on the next notification — no restart needed.