-
Notifications
You must be signed in to change notification settings - Fork 798
命令输入 UX 问题:需要敲两次回车才能执行命令 || UX problem: You need to hit Enter twice to execute the command #1682
Copy link
Copy link
Open
Description
问题描述
在使用命令补全功能时,用户需要敲两次回车才能执行命令,这与其他 CLI 工具(如 Claude Code)的行为不一致,严重影响使用体验。
复现步骤
- 在输入框输入命令的缩写,如
/cl - 敲回车
预期行为:
- 命令自动补全为
/clear并直接执行(参考 Claude Code 的行为) - 用户只需要敲一次回车
实际行为:
- 命令补全为
/clear但不执行 - 用户需要再敲一次回车才能执行
- 总共需要敲两次回车
对比
| CLI 工具 | 输入 | 操作 | 结果 |
|---|---|---|---|
| Claude Code | /cl |
敲回车 × 1 | ✅ 直接执行 /clear |
| kimi-cli | /cl |
敲回车 × 2 | ❌ 需要两次回车才能执行 |
影响
这个问题严重影响使用效率和体验:
- 打断了用户的操作流程
- 与用户的预期行为不符(敲回车 = 执行命令)
- 与业界其他 CLI 工具的行为不一致
建议
建议参考 Claude Code 等工具的实现:
- 用户敲回车时,如果有命令补全,应该自动补全并立即执行
- 不需要用户二次确认
Problem description
When using the command completion function, the user needs to press Enter twice to execute the command. This is inconsistent with the behavior of other CLI tools (such as Claude Code) and seriously affects the user experience.
Reproduction steps
- Enter the abbreviation of the command in the input box, such as
/cl - Press Enter
Expected Behavior:
- Command auto-completion is
/clearand direct execution (refer to Claude Code's behavior) - Users only need to type enter once
Actual behavior:
- Command completion is
/clearbut not executed - The user needs to press Enter again to execute
- You need to hit Enter twice in total**
Compare
| CLI Tools | Input | Actions | Results |
|---|---|---|---|
| Claude Code | /cl |
Hit Enter × 1 | ✅ Directly execute /clear |
| kimi-cli | /cl |
Press Enter × 2 | ❌ Two press Enters are required to execute |
Impact
This problem seriously affects usage efficiency and experience:
- Interrupt the user's operation flow
- does not match the user's expected behavior (hit Enter = execute command)
- Inconsistent behavior with other CLI tools in the industry
Suggestions
It is recommended to refer to the implementation of tools such as Claude Code:
- When the user presses Enter, if there is a command completion, it should be automatically completed and executed immediately
- No need for the user to confirm the command input twice
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels