Skip to main content

vtcode_core/utils/
ansi_codes.rs

1//! ANSI escape sequence constants and utilities
2//!
3//! Re-exports from vtcode-commons for backward compatibility.
4//! See `docs/reference/ansi-in-vtcode.md` for workspace usage guidance.
5
6pub use vtcode_commons::ansi_codes::*;
7
8pub fn notify_attention_with_terminal_method(
9    default_enabled: bool,
10    message: Option<&str>,
11    method: vtcode_config::TerminalNotificationMethod,
12) {
13    let override_mode = match method {
14        vtcode_config::TerminalNotificationMethod::Auto => NotifyMethodOverride::Auto,
15        vtcode_config::TerminalNotificationMethod::Bel => NotifyMethodOverride::Bell,
16        vtcode_config::TerminalNotificationMethod::Osc9 => NotifyMethodOverride::Osc9,
17    };
18
19    notify_attention_with_mode(default_enabled, message, override_mode);
20}