summaryrefslogtreecommitdiffstats
path: root/src/main.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/main.rs')
-rw-r--r--src/main.rs15
1 files changed, 5 insertions, 10 deletions
diff --git a/src/main.rs b/src/main.rs
index 8ce16cc..57d561c 100644
--- a/src/main.rs
+++ b/src/main.rs
@@ -23,6 +23,10 @@ fn main() {
let site = &config.site;
let mut ls = LocalStorage::new()?;
+ if let Some(key) = opts.set_api_key {
+ config::set_api_key(key)?;
+ }
+
if opts.update_sites {
ls.update_sites()?;
}
@@ -88,7 +92,7 @@ fn main() {
this shouldn't be possible!",
)
})?;
- // TODO eventually do this in the right place, e.g. abstract out md parser & do within threads
+ // TODO eventually do this in the right place, e.g. abstract out md parser, write benches, & do within threads
let md = ans.body.replace("<kbd>", "**[").replace("</kbd>", "]**");
skin.print_text(&md);
}
@@ -104,12 +108,3 @@ fn main() {
println!("panic! {}", e.error);
});
}
-
-#[cfg(test)]
-mod tests {
-
- #[test]
- fn test_main() {
- //TODO
- }
-}