Expand description
Desktop notification system for task completion and failures.
Responsibilities:
- Send cross-platform desktop notifications via notify-rust.
- Play optional sound alerts using platform-specific mechanisms.
- Provide graceful degradation when notification systems are unavailable.
- Support different notification types: task success, task failure, loop completion.
Does NOT handle:
- Notification scheduling or queuing (callers trigger explicitly).
- Persistent notification history or logging.
- UI mode detection (callers should suppress if desired).
- Do Not Disturb detection (handled at call site if needed).
Invariants:
- Sound playback failures don’t fail the notification.
- Notification failures are logged but don’t fail the calling operation.
- All platform-specific code is isolated per target OS.
Structs§
- Notification
Config - Configuration for desktop notifications.
- Notification
Overrides - CLI overrides for notification settings.
Fields are
Option<bool>to distinguish “not set” from explicit false.
Enums§
- Notification
Type - Types of notifications that can be sent.
Functions§
- build_
notification_ config - Build a runtime NotificationConfig from config and CLI overrides.
- notify_
loop_ complete - Send loop completion notification. Silently logs errors but never fails the calling operation.
- notify_
task_ complete - Send task completion notification. Silently logs errors but never fails the calling operation.
- notify_
task_ complete_ with_ context - Send task completion notification with UI awareness. Silently logs errors but never fails the calling operation.
- notify_
task_ failed - Send task failure notification. Silently logs errors but never fails the calling operation.
- notify_
watch_ new_ task - Send watch mode notification for newly detected tasks. Silently logs errors but never fails the calling operation.
- play_
completion_ sound - Play completion sound using platform-specific mechanisms.
- send_
notification - Send a notification based on the notification type. Silently logs errors but never fails the calling operation.