From 488002f4bcbab481c240bddbf97f4114bfb58447 Mon Sep 17 00:00:00 2001 From: Darren Schroeder <343840+fdncred@users.noreply.github.com> Date: Thu, 20 Jul 2023 06:48:18 -0500 Subject: [PATCH] add range input to par-each (#9749) # Description Thie PR adds `Type::Range` input to `par-each` to allow `1..3 | do something` again. closes #9748 # User-Facing Changes # Tests + Formatting # After Submitting --- crates/nu-command/src/filters/par_each.rs | 2 ++ 1 file changed, 2 insertions(+) diff --git a/crates/nu-command/src/filters/par_each.rs b/crates/nu-command/src/filters/par_each.rs index 324f8f0fd..b3bfc262d 100644 --- a/crates/nu-command/src/filters/par_each.rs +++ b/crates/nu-command/src/filters/par_each.rs @@ -28,6 +28,7 @@ impl Command for ParEach { Type::List(Box::new(Type::Any)), Type::List(Box::new(Type::Any)), ), + (Type::Range, Type::List(Box::new(Type::Any))), (Type::Table(vec![]), Type::List(Box::new(Type::Any))), ]) .named( @@ -41,6 +42,7 @@ impl Command for ParEach { SyntaxShape::Closure(Some(vec![SyntaxShape::Any, SyntaxShape::Int])), "the closure to run", ) + .allow_variants_without_examples(true) .category(Category::Filters) }