We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 58f8c75 commit e380c8aCopy full SHA for e380c8a
sourced/cool-oneliners/find_in.nu
@@ -3,10 +3,10 @@ def "find in" [
3
glob: glob, # the glob expression
4
...rest: any # terms to search
5
]: nothing -> table<path: string, line: int, data: string> {
6
- glob $glob
+ glob --no-dir $glob
7
| par-each {|e|
8
open $e | lines | enumerate | rename line data |
9
- find -c [data] ...$rest |
+ find --columns [data] ...$rest |
10
each {|match| {path: ($e | path relative-to $env.PWD), ...$match}}
11
} | flatten
12
}
0 commit comments