diff options
author | Hristo Venev <hristo@venev.name> | 2019-09-28 16:12:03 +0000 |
---|---|---|
committer | Hristo Venev <hristo@venev.name> | 2019-09-28 16:12:03 +0000 |
commit | 167a766f488091a9e6d833bb64e7e7cf8f90111f (patch) | |
tree | 568621ba7309be674821aae0684ca2378d063e0e /src/main.rs | |
parent | a66bdaee155d9012b1fd75bf31332df638d49857 (diff) |
Split updater into module.
Diffstat (limited to 'src/main.rs')
-rw-r--r-- | src/main.rs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/main.rs b/src/main.rs index 4ae628e..cfd9c82 100644 --- a/src/main.rs +++ b/src/main.rs @@ -89,7 +89,7 @@ fn cli_config(args: &mut impl Iterator<Item = OsString>) -> Option<config::Confi if key == "refresh_sec" { arg = args.next()?; let arg = arg.to_str()?; - cfg.update_config.refresh_sec = u32::from_str(arg).ok()?; + cfg.updater.refresh_sec = u32::from_str(arg).ok()?; continue; } if key == "source" { @@ -187,7 +187,7 @@ fn run_with_cmdline(argv0: &str, args: &mut impl Iterator<Item = OsString>) -> i } fn run_daemon(ifname: OsString, mut config: config::Config) -> i32 { - maybe_get_var(&mut config.cache_directory, "CACHE_DIRECTORY"); + maybe_get_var(&mut config.updater.cache_directory, "CACHE_DIRECTORY"); maybe_get_var(&mut config.runtime_directory, "RUNTIME_DIRECTORY"); let mut m = match manager::Manager::new(ifname, config) { |