Change missing config log level to info

This commit is contained in:
Tezkerek 2018-12-08 22:51:36 +02:00 committed by Christian Duerr
parent f32facfbfd
commit aef38d6c2f
2 changed files with 7 additions and 2 deletions

View File

@ -21,6 +21,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
### Changed
- Extra padding is not evenly spread around the terminal by default anymore
- When the config file is empty, Alacritty now logs an info instead of an error message
### Fixed

View File

@ -46,7 +46,7 @@ extern crate winapi;
use winapi::um::wincon::{AttachConsole, FreeConsole, ATTACH_PARENT_PROCESS};
use alacritty::cli;
use alacritty::config::{self, Config};
use alacritty::config::{self, Config, Error as ConfigError};
use alacritty::display::Display;
use alacritty::event;
use alacritty::event_loop::{self, EventLoop, Msg};
@ -101,7 +101,11 @@ fn load_config(options: &cli::Options) -> Config {
});
Config::load_from(&*config_path).unwrap_or_else(|err| {
error!("Error: {}; Loading default config", err);
match err {
ConfigError::Empty => info!("Config file {:?} is empty; Loading default", config_path),
_ => error!("Error: {}; Loading default config", err),
}
Config::default()
})
}