github / github/copilot-cli

Add --no-session-cache flag

未關閉
#2,996 0 則留言 1 個 reaction 已指派 0 人 在 GitHub 檢視
area:non-interactive area:sessions
主要語言
Shell
星號
11.2k
分支
1.9k
平均合併
14 小時 16 分鐘
30 天內合併 PR
6

描述

### Describe the feature or problem you'd like to solve

Add a flag that blocks caching the session (to avoid cluttering up session list in `copilot --resume`)

### Proposed solution

Put session caching behind a flag (default TRUE) which can be overridden by the argument `--no-session-cache` so that the user can manually block caching for a session that is expected to be disposable. This would be especially helpful for use together with `copilot --no-session-cache --prompt ...` since prompt calls are virtually never going to require `--resume`ing.

### Example prompts or workflows

```console
$ copilot --no-session-cache --prompt "..."
# The prompt session is not cached
$ copilot --resume
# The list of cached sessions does NOT contain the `--prompt` call above.

### Additional context

_No response_

貢獻指南

開啟貢獻指南

研究方向

Start at the CLI argument parsing entry point and trace how sessions are added to the cache used by `copilot --resume`. Exercise `copilot --no-session-cache --prompt "..."`, then run `copilot --resume`; done means the prompt session is absent from the cached session list while normal sessions remain cached.

由索引模型根據 Issue 內容生成。

評估

技術堆疊
shell
領域
cli
Issue 類型
功能
難度
3/5
預估耗時
1-2 天
活躍度
冷清
描述清晰度
基本清楚
新手友好度
68/100

把新 issue 寄到你的電子郵件信箱

精選適合新手參與的 GitHub issue 摘要。