From 3310537e215a5d1c1ee1826f4ceee6367d7ca08a Mon Sep 17 00:00:00 2001 From: Chris Olszewski Date: Fri, 14 Mar 2025 13:01:25 -0400 Subject: [PATCH] docs(run): fix passthrough arg behavior --- crates/turborepo-lib/src/opts.rs | 7 +++++++ docs/site/content/repo-docs/reference/run.mdx | 2 +- 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/crates/turborepo-lib/src/opts.rs b/crates/turborepo-lib/src/opts.rs index 11c8a25c79556..9c098802e5a60 100644 --- a/crates/turborepo-lib/src/opts.rs +++ b/crates/turborepo-lib/src/opts.rs @@ -892,6 +892,13 @@ mod test { Some(vec!["passthrough".to_string()]); "multiple tasks" )] + #[test_case( + vec!["test".to_string()], + vec!["passthrough".to_string()], + TaskId::new("web", "build"), + None; + "different task" + )] #[test_case( vec!["web#build".to_string()], vec!["passthrough".to_string()], diff --git a/docs/site/content/repo-docs/reference/run.mdx b/docs/site/content/repo-docs/reference/run.mdx index 5e555b6231ab2..b0233d921e10f 100644 --- a/docs/site/content/repo-docs/reference/run.mdx +++ b/docs/site/content/repo-docs/reference/run.mdx @@ -13,7 +13,7 @@ turbo run [tasks] [options] [-- [args passed to tasks]] - **[tasks]**: Turborepo can run one or many tasks at the same time. To run a task through `turbo`, it must be specified in `turbo.json`. - **[options]**: Options are used to control the behavior of the `turbo run` command. Available flag options are described below. -- **[-- [args passed to tasks]]**: You may also pass arguments to the underlying scripts. Note that all arguments will be passed to all tasks. +- **[-- [args passed to tasks]]**: You may also pass arguments to the underlying scripts. Note that all arguments will be passed to all tasks that are named in the run command. `turbo run` is aliased to `turbo`. `turbo run build lint check-types` is the