diff --git a/README.md b/README.md index f0df79b..0a089d3 100644 --- a/README.md +++ b/README.md @@ -20,6 +20,34 @@ cargo build # build cargo run # run ``` +## extensions + +### colored usernames + +#### bRAC + +regex - `\[(.*?)\] \uB9AC\u3E70<(.*?)> (.*)` \ +color - green \ +example - `[date] 리㹰 text` + +#### CRAB + +regex - `\[(.*?)\] \u2550\u2550\u2550<(.*?)> (.*)` \ +color - light red \ +example - `[date] ═══ text` + +#### Mefedroniy + +regex - `\[(.*?)\] (.*?): (.*)` \ +color - light magenta \ +example - `[date] nick: text` + +#### clRAC + +regex - `\[(.*?)\] <(.*?)> (.*)` \ +color - cyan \ +example - `[date] text` + ## see also - [CRAB - client & server for RAC](https://gitea.bedohswe.eu.org/pixtaded/crab) diff --git a/src/main.rs b/src/main.rs index ca35035..aa8f843 100644 --- a/src/main.rs +++ b/src/main.rs @@ -9,7 +9,7 @@ use termion::{event::Key, input::TermRead, raw::IntoRawMode}; const MAX_MESSAGES: usize = 100; const DEFAULT_HOST: &str = "meex.lol:11234"; -const MAGIC_KEY: &str = "리㹰"; +const MAGIC_KEY: &str = "\u{B9AC}\u{3E70}"; fn send_message(host: &str, message: &str) -> Result<(), Box> { let mut stream = TcpStream::connect(host)?;