alacritty

Unnamed repository; edit this file 'description' to name the repository.
Log | Files | Refs | README

commit aef38d6c2fb384cf29a948a19c67733960983d3b
parent f32facfbfd3d46b76744d118fd2fa5123501f900
Author: Tezkerek <andrei.ancuta@gmail.com>
Date:   Sat,  8 Dec 2018 22:51:36 +0200

Change missing config log level to info


Diffstat:
MCHANGELOG.md | 1+
Msrc/main.rs | 8++++++--
2 files changed, 7 insertions(+), 2 deletions(-)

diff --git a/CHANGELOG.md b/CHANGELOG.md @@ -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 diff --git a/src/main.rs b/src/main.rs @@ -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() }) }