pit

Crates.iopit
lib.rspit
version0.1.0
sourcesrc
created_at2018-01-17 11:49:29.752815
updated_at2018-01-17 11:49:29.752815
descriptionpit in Rust
homepage
repositoryhttps://github.com/hhatto/pit-rs
max_upload_size
id47170
size20,667
Hideo Hattori (hhatto)

documentation

https://docs.rs/pit

README

pit-rs

pit for Rust

Usage

[dependencies]
pit = { git = "https://github.com/hhatto/pit-rs", branch = "master" }
extern crate pit;

use pit::Pit;

fn main() {
    let p = Pit::new();
    let config = p.get("twitter.com");
    match config {
        None => {
            println!("not provide config value");
            return;
        },
        Some(_) => {},
    }

    let config = config.unwrap();
    let username = config.get("username").unwrap();
    let password = config.get("password").unwrap();
    println!("username={}, password={}", username, password);
}

for developer

$ cargo test -- --test-threads=1
Commit count: 16

cargo fmt