pub const DAY: u64 = 86_400; pub const HOUR: u64 = 3_600; pub const MINUTE: u64 = 60; pub const HELP_STRINGS: [&'static str; 22] = [ "help/lang", "help/timezone", "help/prefix", "help/blacklist", "help/restrict", "help/alias", "help/remind", "help/interval", "help/natural", "help/look", "help/del", "help/offset", "help/pause", "help/nudge", "help/info", "help/help", "help/donate", "help/clock", "help/todo", "help/todos", "help/todoc", "help/timer", ]; pub const CHARACTERS: &str = "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789_"; const THEME_COLOR_FALLBACK: u32 = 0x8fb677; use std::{collections::HashSet, env, iter::FromIterator}; use regex::Regex; lazy_static! { pub static ref REGEX_CHANNEL: Regex = Regex::new(r#"^\s*<#(\d+)>\s*$"#).unwrap(); pub static ref REGEX_ROLE: Regex = Regex::new(r#"<@&(\d+)>"#).unwrap(); pub static ref REGEX_COMMANDS: Regex = Regex::new(r#"([a-z]+)"#).unwrap(); pub static ref REGEX_ALIAS: Regex = Regex::new(r#"(?P[\S]{1,12})(?:(?: (?P.*)$)|$)"#).unwrap(); pub static ref REGEX_CONTENT_SUBSTITUTION: Regex = Regex::new(r#"<<(\d+)>>"#).unwrap(); pub static ref REGEX_CHANNEL_USER: Regex = Regex::new(r#"\s*<(#|@)(?:!)?(\d+)>\s*"#).unwrap(); pub static ref REGEX_REMIND_COMMAND: Regex = Regex::new( r#"(?P(?:<@\d+>\s|<@!\d+>\s|<#\d+>\s)*)(?P