Skip to content

Commit e380c8a

Browse files
authored
Fixed bug where find_in globs were matching directories (#980)
1 parent 58f8c75 commit e380c8a

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

sourced/cool-oneliners/find_in.nu

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,10 +3,10 @@ def "find in" [
33
glob: glob, # the glob expression
44
...rest: any # terms to search
55
]: nothing -> table<path: string, line: int, data: string> {
6-
glob $glob
6+
glob --no-dir $glob
77
| par-each {|e|
88
open $e | lines | enumerate | rename line data |
9-
find -c [data] ...$rest |
9+
find --columns [data] ...$rest |
1010
each {|match| {path: ($e | path relative-to $env.PWD), ...$match}}
1111
} | flatten
1212
}

0 commit comments

Comments
 (0)