From ce8e4fb921b33283dcedb44e78a6aa312a3a0a49 Mon Sep 17 00:00:00 2001 From: Ryan Cao <70191398+ryanccn@users.noreply.github.com> Date: Mon, 20 Nov 2023 16:37:09 +0800 Subject: [PATCH] fix: allow run-script in nested compat mode --- src/main.rs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/main.rs b/src/main.rs index cd4d60f..3e3dd65 100644 --- a/src/main.rs +++ b/src/main.rs @@ -142,7 +142,9 @@ async fn main() -> Result<()> { let cli = Cli::parse_from( if env::var_os("NRR_COMPAT_MODE").is_some_and(|v| !v.is_empty()) - && raw_args.get(1) == Some(&"run".to_owned()) + && raw_args + .get(1) + .is_some_and(|v| v == "run" || v == "run-script") { let mut processed_args = raw_args.clone(); processed_args.remove(1);