Skip to content

feat: add /export and /import commands to shell mode; update context …#1330

Merged
RealKai42 merged 1 commit intomainfrom
kaiyi/docs/0303
Mar 3, 2026
Merged

feat: add /export and /import commands to shell mode; update context …#1330
RealKai42 merged 1 commit intomainfrom
kaiyi/docs/0303

Conversation

@RealKai42
Copy link
Copy Markdown
Collaborator

@RealKai42 RealKai42 commented Mar 3, 2026

Checklist

  • I have read the CONTRIBUTING document.
  • I have linked the related issue, if any.
  • I have added tests that prove my fix is effective or that my feature works.
  • I have run make gen-changelog to update the changelog.
  • I have run make gen-docs to update the user documentation.

Open with Devin

Copilot AI review requested due to automatic review settings March 3, 2026 15:06
@RealKai42 RealKai42 merged commit 34ea138 into main Mar 3, 2026
12 checks passed
@RealKai42 RealKai42 deleted the kaiyi/docs/0303 branch March 3, 2026 15:09
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Updates the user guides to reflect recent shell/status-bar behavior changes in Kimi Code CLI, especially around context display and shell-mode slash commands.

Changes:

  • Update session guides (EN/ZH) to mention token counts shown alongside context usage in the status bar.
  • Update interaction guides (EN/ZH) to list /export and /import as supported slash commands in shell mode.

Reviewed changes

Copilot reviewed 4 out of 4 changed files in this pull request and generated 4 comments.

File Description
docs/zh/guides/sessions.md Document token-count-inclusive context status bar display (ZH).
docs/zh/guides/interaction.md Add /export and /import to shell-mode slash command list (ZH).
docs/en/guides/sessions.md Document token-count-inclusive context status bar display (EN).
docs/en/guides/interaction.md Add /export and /import to shell-mode slash command list (EN).

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.


::: tip
The bottom status bar displays the current context usage (`context: xx.x%`), helping you understand when you need to clear or compact.
The bottom status bar displays the current context usage with token counts (e.g., `context: 42.0% (4.2k/10.0k)`), helping you understand when you need to clear or compact.
Copy link

Copilot AI Mar 3, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The example token count format doesn’t match the actual status formatter: format_token_count() drops trailing .0, so 10.0k would display as 10k. Consider updating the example to something like context: 42.0% (4.2k/10k) to reflect real output.

Suggested change
The bottom status bar displays the current context usage with token counts (e.g., `context: 42.0% (4.2k/10.0k)`), helping you understand when you need to clear or compact.
The bottom status bar displays the current context usage with token counts (e.g., `context: 42.0% (4.2k/10k)`), helping you understand when you need to clear or compact.

Copilot uses AI. Check for mistakes.

::: tip 提示
底部状态栏会显示当前的上下文使用率(`context: xx.x%`),帮助你了解何时需要清空或压缩。
底部状态栏会显示当前的上下文使用率和 Token 数量(如 `context: 42.0% (4.2k/10.0k)`),帮助你了解何时需要清空或压缩。
Copy link

Copilot AI Mar 3, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

示例里的 Token 格式和实际状态栏输出不一致:format_token_count() 会去掉末尾的 .0,因此 10.0k 实际会显示为 10k。建议把示例改成类似 context: 42.0% (4.2k/10k) 以匹配真实输出。

Suggested change
底部状态栏会显示当前的上下文使用率和 Token 数量(如 `context: 42.0% (4.2k/10.0k)`),帮助你了解何时需要清空或压缩。
底部状态栏会显示当前的上下文使用率和 Token 数量(如 `context: 42.0% (4.2k/10k)`),帮助你了解何时需要清空或压缩。

Copilot uses AI. Check for mistakes.
Shell mode also supports some slash commands, including `/help`, `/exit`, `/version`, `/editor`, `/changelog`, `/feedback`, `/export`, and `/import`.

::: warning Note
In shell mode, each command executes independently. Commands that change the environment like `cd` or `export` won't affect subsequent commands.
Copy link

Copilot AI Mar 3, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Now that /export is listed as a supported slash command in shell mode, the warning below becomes ambiguous because it mentions export (the shell built-in) without a slash. Consider clarifying that the warning refers to environment-changing shell commands (e.g., export FOO=bar) and is unrelated to the /export slash command.

Suggested change
In shell mode, each command executes independently. Commands that change the environment like `cd` or `export` won't affect subsequent commands.
In shell mode, each command executes independently. Shell built-ins that change the environment, like `cd` or `export FOO=bar` (not the `/export` slash command), won't affect subsequent commands.

Copilot uses AI. Check for mistakes.
Shell 模式也支持部分斜杠命令,包括 `/help`、`/exit`、`/version`、`/editor`、`/changelog`、`/feedback`、`/export` 和 `/import`。

::: warning 注意
Shell 模式中每个命令独立执行,`cd`、`export` 等改变环境的命令不会影响后续命令。
Copy link

Copilot AI Mar 3, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

现在在 Shell 模式斜杠命令列表里加入了 /export,但下面的注意事项又写了 export(无斜杠,指 shell 内建命令),容易让读者误以为和 /export 是同一件事。建议在提示里明确这是指修改环境的 shell 命令(例如 export FOO=bar),并说明与 /export 斜杠命令无关。

Suggested change
Shell 模式中每个命令独立执行,`cd``export` 等改变环境的命令不会影响后续命令
Shell 模式中每个命令独立执行,这里的 `cd``export` 等是指修改环境的 Shell 命令(例如 `export FOO=bar`),不会影响后续命令,且与上面的 `/export` 斜杠命令无关

Copilot uses AI. Check for mistakes.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants