diff --git a/crates/lib/twitch_common/Cargo.toml b/crates/lib/twitch_common/Cargo.toml new file mode 100644 index 0000000000..e82dc8e63b --- /dev/null +++ b/crates/lib/twitch_common/Cargo.toml @@ -0,0 +1,22 @@ +[package] +name = "twitch_common" +edition = "2018" +version = "0.0.1" +authors = [ + "Brandon Thomas ", + "Brandon Thomas ", +] +publish = false + +[lib] +name = "twitch_common" +path = "src/lib.rs" + +[dependencies] + +# Internal +container_common = { path = "../container_common" } + +# External +anyhow = "1.0.40" +once_cell = "1.9.0" diff --git a/crates/lib/twitch_common/src/cheers.rs b/crates/lib/twitch_common/src/cheers.rs new file mode 100644 index 0000000000..fda0b5de45 --- /dev/null +++ b/crates/lib/twitch_common/src/cheers.rs @@ -0,0 +1,47 @@ +use once_cell::sync::Lazy; +use std::collections::HashSet; + +/// These cheer emotes always combine with a number +/// This list seems pretty comprehensive +/// https://github.com/nossebro/TwitchPubSubMirror/blob/master/TwitchPubSubMirror_StreamlabsSystem.py + +static TWITCH_CHEERS : Lazy> = Lazy::new(|| { + let cheers = vec![ + "Cheer", + "DoodleCheer", + "BibleThump", + "cheerwhal", + "Corgo", + "uni", + "ShowLove", + "Party", + "SeemsGood", + "Pride", + "Kappa", + "FrankerZ", + "HeyGuys", + "DansGame", + "EleGiggle", + "TriHard", + "Kreygasm", + "4Head", + "SwiftRage", + "NotLikeThis", + "FailFish", + "VoHiYo", + "PJSalt", + "MrDestructoid", + "bday", + "RIPCheer", + "Shamrock", + "BitBoss", + "Streamlabs", + "Muxy", + "HolidayCheer" + ]; + let mut s = HashSet::new(); + for cheer in cheers.into_iter() { + s.insert(cheer.to_string()); + } + s +}); diff --git a/crates/lib/twitch_common/src/lib.rs b/crates/lib/twitch_common/src/lib.rs new file mode 100644 index 0000000000..3d395e4749 --- /dev/null +++ b/crates/lib/twitch_common/src/lib.rs @@ -0,0 +1 @@ +pub mod cheers; \ No newline at end of file