Add a "check-config" command to validate config files & tests for it

This commit is contained in:
Andreas Fuchs 2024-10-04 10:49:08 -04:00
parent 70ee206031
commit 26ba489aa3
24 changed files with 492 additions and 0 deletions

11
src/cli/check_config.rs Normal file
View file

@ -0,0 +1,11 @@
use tracing::info;
use crate::{cli::ConfigArg, config, error};
pub(crate) async fn run(
args: ConfigArg,
) -> Result<(), error::CheckConfigCommand> {
let _config = config::load(args.config.as_ref()).await?;
info!("Configuration looks good");
Ok(())
}