Crates.io | code-search |
lib.rs | code-search |
version | 0.0.3 |
source | src |
created_at | 2024-08-19 13:24:17.665869 |
updated_at | 2024-08-25 09:54:37.451053 |
description | A command-line code search tool. |
homepage | https://github.com/feint123 |
repository | https://github.com/feint123/code-search |
max_upload_size | |
id | 1343871 |
size | 71,289 |
一个可以在命令行中使用的代码搜索工具
Usage: code-search [OPTIONS] --key <Key>
Options:
-p, --path <Path> 搜索路径,文件或目录 [default: .]
-l, --language <Language> 使用语言文件扩展名,如 rs、md等
-s, --symbol 只搜索符号,如类名、函数名称等
-k, --key <Key> 关键字
-r, --reg 启用正则表达式(会减缓搜索速度)
-i, --interactive 启用交互模式(该模式会构建索引,请指定具体的项目目录)
-h, --help Print help
-V, --version Print version
symbol 搜索支持以下语言:
支持符号搜索,查看文件大纲
❯ code-search -i
当前根路径为 : /Volumes/T7/Github/code-search
>> main
main(/Volumes/T7/Github/code-search/examples/main.c:23)
main(/Volumes/T7/Github/code-search/examples/main.cpp:27)
main(/Volumes/T7/Github/code-search/examples/main.go:51)
main(/Volumes/T7/Github/code-search/examples/Main.java:31)
main(/Volumes/T7/Github/code-search/examples/main.py:48)
main(/Volumes/T7/Github/code-search/src/main.rs:32)
>> outline /Volumes/T7/Github/code-search/examples/main.go
type Shape interface
Area
Perimeter
type Rectangle struct
Width
Height
func (r Rectangle) Area () float64
func (r Rectangle) Perimeter () float64