Skip to main content

code-navigation

Jump to symbol definitions, find all references, locate interface declarations, resolve type definitions, and find implementations. Use instead of grep or text search when navigating to where a function, type, or variable is defined or used. Activated by runectl lsp.

跳到安装

来源信息

仓库
unstablebuild/rune
最近来源活动
2026年3月26日 19:53
检测到的 SKILL.md 语言
英语
星标
1,035
分支
80

安装方式

默认使用会先检查来源的 Prompt;你也可以切换为直接命令,或下载本地副本。

检查来源文件

决定是否安装前,请先阅读 SKILL.md,以及 SkillsMP 当前展示的配套文件。

正在显示 SKILL.md

SKILL.md
来源说明 · 只读预览
name
code-navigation
description
Jump to symbol definitions, find all references, locate interface declarations, resolve type definitions, and find implementations. Use instead of grep or text search when navigating to where a function, type, or variable is defined or used. Activated by runectl lsp.
allowed-tools
Bash(runectl:*)
# Code Navigation Semantic code navigation via `runectl lsp`. Prefer these over grep — they use the language server for precise results. ## runectl lsp definition Go to definition. ``` Usage: runectl lsp definition (<file> <line> <col> | <symbol>) [flags] Flags: -F, --format string Output format: table, json, or Go template ``` Use when you see a function call and want its source. Example — find where the `workspaceapi.Cmd` struct is defined: ```bash $ runectl lsp definition workspaceapi.Cmd file:///src/rune-go-sdk/api/workspaceapi/workspace.go 52:5-52:8 ``` The result points to `workspace.go` line 52, columns 5-8. ## runectl lsp references Find all references. ``` Usage: runectl lsp references (<file> <line> <col> | <symbol>) [flags] Flags: -d, --declaration Include declaration -F, --format string Output format: table, json, or Go template ``` Use to find every place a symbol is used across the workspace. Example — find all usages of `workspaceapi.URI`: ```bash $ runectl lsp references workspaceapi.URI file:///src/rune-agent/agent/agent.go 153:39-153:42 file:///src/rune-agent/agent/agent.go 161:39-161:42 file:///src/rune-agent/agent/agent.go 174:32-174:35 ... ``` Each line is a location where `URI` appears. Add `-d` to also include the declaration itself. ## runectl lsp declaration Go to declaration. ``` Usage: runectl lsp declaration (<file> <line> <col> | <symbol>) [flags] Flags: -F, --format string Output format: table, json, or Go template ``` Use when you want the interface a method satisfies or a forward declaration. ## runectl lsp type-definition Go to type definition. ``` Usage: runectl lsp type-definition (<file> <line> <col> | <symbol>) [flags] Flags: -F, --format string Output format: table, json, or Go template ``` Use when you have a variable and want its underlying struct or interface type. Example — find the type behind `workspaceapi.Cmd`: ```bash $ runectl lsp type-definition workspaceapi.Cmd file:///src/rune-go-sdk/api/workspaceapi/workspace.go 52:5-52:8 ``` ## runectl lsp implementation Find implementations. ``` Usage: runectl lsp implementation (<file> <line> <col> | <symbol>) [flags] Flags: -F, --format string Output format: table, json, or Go template ``` Use when you have an interface and want all concrete types that implement it. Example — find all types implementing `workspaceapi.Executor`: ```bash $ runectl lsp implementation workspaceapi.Executor file:///src/rune-go-sdk/api/workspaceapi/workspacerpc/client.go 44:5-44:11 file:///src/rune-agent/agent/agentools/agentools_test.go 85:5-85:14 file:///src/rune-agent/agent/agentools/agentools_test.go 123:5-123:18 ... ``` Results include test doubles across the workspace and the real client in `workspacerpc`.
在 GitHub 查看