argument-hint doesn't show for skills
还没有人认领这个 Issue。
评估
- 难度
- 2/5
- 预计耗时
- 1-3 小时
- 新手友好度
- 75/100
- Issue 类型
- 缺陷
- 描述清晰度
- 描述清楚
- 活跃度
- 活跃
- 技术栈
- javascript, nodejs
- 领域
- cli
调研方向
从报告中提到的 skill 转命令环节 cliSlashSkillMetadata 开始:它接收到了正确的 argumentHint,但返回的命令元数据中没有 args 字段。对比 /model 等内置命令如何填充 args 以显示提示,然后在那里将该 skill 的 argumentHint 设置为字面量参数。验证时,按照复现步骤创建 .github/skills/hint-repro/SKILL.md,在该项目中启动 CLI 会话并输入 /hint-repro。当建议列表和输入行中都显示 [target] [--help](无论末尾是否有空格)时即完成。
由索引模型根据 Issue 内容生成。
描述
Describe the bug
A skill's description appears when typing its slash command, but its argument hint doesn't. The installed SKILL.md has a quoted, top-level argument-hint field in its YAML frontmatter
Affected version
1.0.115-8
Steps to reproduce the behavior
- In a local test project, create
.github/skills/hint-repro/SKILL.mdwith this content:
---
name: hint-repro
description: Test whether skill argument hints are displayed.
argument-hint: "[target] [--help]"
---
If invoked, reply with "Hint test." Do not use tools.
- Start a fresh Copilot CLI session in that project
- Type
/hint-reprowithout pressing Enter. Check the command suggestion and input line for[target] [--help] - Add a trailing space and check again
The configured argument hint should be displayed. There is no need to submit the command or execute the skill
Expected behavior
The configured argument hint should appear when selecting or typing the skill's slash command, as described under “Skill frontmatter fields”:
Additional context
Reproduced on macOS ARM64
Built-in commands such as /model show their argument hints in the same terminal
While investigating, I found that cliSlashSkillMetadata receives the correct argumentHint, but the returned command metadata has no args field. In a temporary test process, adding this to the returned command made the full hint appear:
command.args = [{ type: "literal", text: skill.argumentHint }];
Removing that change made the hint disappear again
That seems to narrow it down to the skill-to-command conversion
I only tested the display behaviour, so the snippet above isn't intended as a complete fix
- 主要语言
- Python
- 星标
- 11.5k
- 派生
- 2k
- 平均合并
- 6 小时 34 分钟
- 30 天内合并 PR
- 3
环境准备
- 没有 Dockerfile 或 Docker Compose 文件
- 没有 Pull Request 模板
- 阅读贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
github/copilot-cli 的其他 Issue
-
难度 1/5 1-3 小时 新手友好度 78/100
github/copilot-cli#5489 ·
-
Built-in functions.view returns no content for large files despite documenting automatic truncation未关闭area:tools
难度 2/5 1-3 小时 新手友好度 72/100
github/copilot-cli#5476 ·
-
triage
难度 1/5 1 小时以内 新手友好度 74/100
github/copilot-cli#5377 ·
-
area:platform-windows area:tools
难度 1/5 1 小时以内 新手友好度 74/100
github/copilot-cli#5340 ·
-
area:configuration area:models
难度 2/5 1-3 小时 新手友好度 67/100
github/copilot-cli#5287 ·
查看 github/copilot-cli 的全部 Issue
相似的 Issue
-
fidelity
难度 2/5 1-3 小时 新手友好度 68/100
维护者通常 1 天内回复
-
backlog
难度 2/5 1-3 小时 新手友好度 72/100
sagemathinc/sagebrush#3434 ·
维护者通常 1 天内回复
-
marketing
难度 2/5 1-3 小时 新手友好度 85/100
维护者通常 1 天内回复
-
documentation good first issue help wanted
难度 2/5 1-3 小时 新手友好度 78/100
wuisabel-gif/MemWhale#576 ·
维护者通常 1 天内回复
-
Status: Triage Suggestion
难度 2/5 1-3 小时 新手友好度 68/100
GTNewHorizons/GT-New-Horizons-Modpack#27957 ·
维护者通常 1 天内回复