[Feature Request] 支持 --project:让 init/update 把 skills 装到项目而非全局
Nobody has claimed this yet.
- Dominant language
- Go
- Stars
- 17.3k
- Forks
- 1.4k
- Avg merge
- 2d 4h
- Merged PRs (30d)
- 105
Description
问题
lark-cli update 和 lark-cli init 都把 25+ 个 lark-* skill 强制装到全局
~/.agents/skills/,且没有 opt-out。这污染了被 Claude Code、Codex、Warp 等
多个 agent 共享的全局 skill 命名空间——即使在跟飞书完全无关的项目里工作,
所有 agent 也会看到这些 skill 的触发描述。
根因
底层 npx skills add 默认就是 project 级安装,-g 是显式覆盖项
(见 npx skills --help)。但 lark-cli 两处都硬编码了 -g:
internal/selfupdate/updater.go:178→npx -y skills add <source> -g -yscripts/install-wizard.js:278→npx -y skills add <source> -y -g
相当于绕过了上游工具的默认值。
建议
给 update 和 init 都加 --project flag(命名与 npx skills 的
-p/--project 保持一致),传入时不要再附加 -g:
// internal/selfupdate/updater.go
args := []string{"-y", "skills", "add", source, "-y"}
if !u.ProjectScope {
args = append(args, "-g")
}
默认行为保持不变(仍为 -g),向后兼容。让用户可以选择把 lark-* skill
限定在实际用到飞书的项目里,而不是强制注入全局命名空间。
环境
@larksuite/cli1.0.38 / 1.0.39(main 分支同样行为)- macOS / Apple Silicon
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with internal/selfupdate/updater.go:178 and scripts/install-wizard.js:278, then trace how the update and init command flags are parsed. Done means both entry points accept --project, preserve the default global installation, and omit -g when project scope is requested; verify the resulting npx skills add arguments with the relevant existing checks.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- go, javascript
- Domain
- cli
- Issue type
- Feature
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Quiet
- Clarity
- Clearly specified
- Newbie friendliness
- 62/100