Skip to content

matteopt/tin

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 

Repository files navigation

tin: Twitch IRC nommer

nom parser for parsing/normalising Twitch (and probably all) IRC messages.

let line = ":tmi.twitch.tv 372 justinfan123 :You are in a maze of twisty passages, all alike.\r\n";
let _m = message(line);
if let Ok((_, m)) = _m {
    println!("{:?}", m);
}

> Message {
      tags: None,
      source: Some("tmi.twitch.tv"),
      command: "372",
      parameters: ["justinfan123", "You are in a maze of twisty passages, all alike."]
  }

Twitch-specific commands

Listed here as quick reference only:

  • CLEARCHAT
    :tmi.twitch.tv CLEARCHAT #<channel> :<user>
  • CLEARMSG
    :tmi.twitch.tv CLEARMSG #<channel> :<message>
  • GLOBALUSERSTATE
    :tmi.twitch.tv GLOBALUSERSTATE
  • HOSTTARGET
    :tmi.twitch.tv HOSTTARGET #<hosting-channel> :[-|<channel>] <number-of-viewers>
  • NOTICE
    :tmi.twitch.tv NOTICE #<channel> :<message>
  • RECONNECT
    :tmi.twitch.tv RECONNECT
  • ROOMSTATE
    :tmi.twitch.tv ROOMSTATE #<channel>
  • USERNOTICE
    :tmi.twitch.tv USERNOTICE #<channel> :[<message>]
  • USERSTATE
    :tmi.twitch.tv USERSTATE #<channel>
  • WHISPER
    :<to-user>!<to-user>@<to-user>.tmi.twitch.tv WHISPER <from-user> :<message>

Releases

No releases published

Packages

 
 
 

Languages