From 0eea049db10e80fdb4a3fffd7915c0c9a2e755b5 Mon Sep 17 00:00:00 2001 From: Hunter Wittenborn Date: Sun, 26 May 2024 03:10:27 -0500 Subject: [PATCH] Show more useful error message when `icons.toml` doesn't exist --- build.rs | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/build.rs b/build.rs index ee18d40..bbaaf7d 100644 --- a/build.rs +++ b/build.rs @@ -72,7 +72,10 @@ fn main() { .to_str() .expect("Couldn't convert manifest directory to string") .to_owned(); - (Config::load(&config_dir).unwrap(), config_dir) + ( + Config::load(&config_dir).expect("Couldn't find `icons.toml` next to `Cargo.toml`"), + config_dir, + ) }; eprintln!("Canonical config dir: {config_dir:?}");