diff --git a/sourced/cool-oneliners/find_in.nu b/sourced/cool-oneliners/find_in.nu index 4f8dc503..20855edb 100644 --- a/sourced/cool-oneliners/find_in.nu +++ b/sourced/cool-oneliners/find_in.nu @@ -3,10 +3,10 @@ def "find in" [ glob: glob, # the glob expression ...rest: any # terms to search ]: nothing -> table { - glob $glob + glob --no-dir $glob | par-each {|e| open $e | lines | enumerate | rename line data | - find -c [data] ...$rest | + find --columns [data] ...$rest | each {|match| {path: ($e | path relative-to $env.PWD), ...$match}} } | flatten }