Added options hashmap to config for custom bot configuration.
This commit is contained in:
parent
f185106e08
commit
7f67bd2905
2 changed files with 3 additions and 1 deletions
|
@ -1 +1 @@
|
|||
echo "{\"owners\": [\"test\"],\"nickname\": \"test\",\"username\": \"test\",\"realname\": \"test\",\"password\": \"\",\"server\": \"irc.fyrechat.net\",\"port\": 6667,\"channels\": [\"#test\", \"#test2\"]}" > config.json
|
||||
echo "{\"owners\": [\"test\"],\"nickname\": \"test\",\"username\": \"test\",\"realname\": \"test\",\"password\": \"\",\"server\": \"irc.fyrechat.net\",\"port\": 6667,\"channels\": [\"#test\", \"#test2\"],\"options\": {}}" > config.json
|
||||
|
|
|
@ -1,3 +1,4 @@
|
|||
use std::collections::HashMap;
|
||||
use std::io::fs::File;
|
||||
use std::io::{InvalidInput, IoError, IoResult};
|
||||
use serialize::json::{decode};
|
||||
|
@ -79,6 +80,7 @@ pub struct Config {
|
|||
pub server: String,
|
||||
pub port: u16,
|
||||
pub channels: Vec<String>,
|
||||
pub options: HashMap<String, String>,
|
||||
}
|
||||
|
||||
impl Config {
|
||||
|
|
Loading…
Add table
Reference in a new issue