From 3240234e95630893d7f962685071ed805df5d08c Mon Sep 17 00:00:00 2001 From: bunnie Date: Wed, 2 Feb 2022 23:56:17 +0800 Subject: [PATCH] re-instate xtask run with command-line specified apps --- xtask/src/main.rs | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/xtask/src/main.rs b/xtask/src/main.rs index fcdf591e0..b2f7bba07 100644 --- a/xtask/src/main.rs +++ b/xtask/src/main.rs @@ -183,6 +183,22 @@ fn main() -> Result<(), Box> { Some("pddb-ci") => run(false, &hw_pkgs, Some( &["--features", "pddb/ci", "--features", "pddb/deterministic"] ))?, + Some("run") => { + let mut args = env::args(); + args.nth(1); + let mut pkgs = hw_pkgs.to_vec(); + let mut apps: Vec = args.collect(); + if apps.len() == 0 { // add the standard demo apps if none are specified + println!("No apps specified, adding default apps..."); + apps.push("ball".to_string()); + apps.push("repl".to_string()); + } + for app in &apps { + pkgs.push(app); + } + generate_app_menus(&apps); + run(false, &pkgs, None)? + }, Some("app-image") => { let mut args = env::args(); args.nth(1);