diff --git a/src/main.rs b/src/main.rs index 49177a6..11362c4 100644 --- a/src/main.rs +++ b/src/main.rs @@ -45,7 +45,6 @@ struct Args { #[clap(short, long, conflicts_with = "config")] qemu_command: Option, /// Command to run in kernel mode. `-` to get an interactive shell. - #[clap(conflicts_with = "config")] command: Vec, } @@ -135,6 +134,13 @@ fn config(args: &Args) -> Result { .target .into_iter() .filter(|t| filter.is_match(&t.name)) + .map(|t| { + let mut t = t; + if !args.command.is_empty() { + t.command = args.command.join(" "); + } + t + }) .collect::>(); let base = config_path.parent().unwrap(); Vmtest::new(base, config)