Crate async_circe[][src]

Expand description

A simple IRC crate written in rust

use async_circe::{commands::Command, Client, Config};
fn main() -> Result<(), tokio::io::Error> {
    let config = Default::default();
    let mut client = Client::new(config).await.unwrap();

    client.identify().await.unwrap();

    loop {
        if let Ok(ref command) = client.read().await {
            if let Command::PRIVMSG(nick, channel, message) = command {
                println!("{} in {}: {}", nick, channel, message);
            }
        }
    }
}

Modules

IRC comamnds

Structs

An IRC client

Config for the IRC client

Custom Error for the read function