You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Add `notification_settings.per_hook` to independently control audio and
desktop notifications per hook type. Frequent hooks like pretooluse can
use audio_only to avoid slow desktop notification queuing, while critical
hooks keep both channels. New `disabled` mode suppresses audio and
desktop but preserves TTS/logging. Fully backward compatible — omitting
per_hook uses the global mode as before.
- Add per-hook mode resolution with validation and fallback in hook_runner.py
- Add `--hook-mode` CLI flag to configure.sh
- Add `disabled` as a valid notification mode
- Update config templates, CLAUDE.md, README.md, CHANGELOG.md
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Copy file name to clipboardExpand all lines: CHANGELOG.md
+20Lines changed: 20 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -5,6 +5,26 @@ All notable changes to Claude Code Audio Hooks will be documented in this file.
5
5
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
6
6
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
7
7
8
+
## [4.3.0] - 2026-02-17
9
+
10
+
### Added
11
+
-**Per-hook notification mode overrides**: New `notification_settings.per_hook` config allows independently controlling audio and desktop notifications per hook type (e.g., `"pretooluse": "audio_only"` to skip desktop notifications for frequent hooks)
12
+
-**`disabled` notification mode**: Suppresses both audio and desktop notifications while still allowing TTS and logging — different from `enabled_hooks: false` which skips everything
- Per-hook mode validation with automatic fallback to global mode on invalid values
15
+
16
+
### Changed
17
+
-`hook_runner.py` notification mode resolution now checks `per_hook` overrides before falling back to global `notification_settings.mode`
18
+
- Debug logging now shows both per-hook and global mode for each hook trigger
19
+
- Updated `config/default_preferences.json` and `config/user_preferences.json` with `per_hook` field
20
+
- Updated CLAUDE.md, README.md with per-hook notification mode documentation
21
+
22
+
### Upgrade
23
+
24
+
No reinstall needed — existing installations self-update automatically on the next hook trigger after `git pull`. The `per_hook` field is fully backward compatible: if absent, all hooks use the global mode as before.
| 4.3.0 | 2026-02-17 | Per-hook notification mode overrides: independently control audio/desktop notifications per hook type via `notification_settings.per_hook`|
Override the global mode for specific hooks. Hooks not listed in `per_hook` fall back to the global `mode`. This is useful when frequent hooks (like `pretooluse`) should only play audio without queuing slow desktop notifications:
805
+
806
+
```json
807
+
{
808
+
"notification_settings": {
809
+
"mode": "audio_and_notification",
810
+
"show_context": true,
811
+
"per_hook": {
812
+
"pretooluse": "audio_only",
813
+
"posttooluse": "audio_only",
814
+
"precompact": "disabled"
815
+
}
816
+
}
817
+
}
818
+
```
819
+
820
+
| Mode | Audio | Desktop Popup | Notes |
821
+
|------|-------|---------------|-------|
822
+
|`audio_only`| Yes | No | Fast, no desktop notification delay |
823
+
|`notification_only`| No | Yes | Visual-only, no audio |
824
+
|`audio_and_notification`| Yes | Yes | Both channels |
825
+
|`disabled`| No | No | Suppresses both (TTS/logging still works) |
826
+
827
+
> **Note:**`"disabled"` is different from `enabled_hooks: false` — the hook still fires for TTS and logging, it just skips audio and desktop notifications.
0 commit comments