github / github/copilot-cli

Allow end-aligned truncation for path and branch footer items

未關閉
#4,591 0 則留言 0 個 reaction 已指派 0 人 在 GitHub 檢視

還沒有人認領這個 Issue。

area:configuration area:terminal-rendering
主要語言
Shell
星號
11.2k
分支
1.9k
平均合併
14 小時 16 分鐘
30 天內合併 PR
6

描述

Describe the feature or problem you'd like to solve

When the path or branch name is too long, only the end is truncated.

Proposed solution

Add a per-item truncation setting to  /footer  (and  /statusline ) for values such as the current working directory and Git branch. Support at least  start  (current behavior),  end , and optionally  middle  truncation. With  end  selected, render an ellipsis followed by the trailing portion of the value—for example,  …\foo\.worktrees\bar  and  …/feature-name —so the most distinguishing directory and branch suffix remain visible in narrow terminals. Persist the preference with the existing footer configuration.

Example prompts or workflows

No response

Additional context

No response

貢獻指南

開啟貢獻指南

從這裡開始

  1. 先讀完整個 Issue,再讀專案的貢獻指南。
  2. 在 Issue 下留言說明你要接手 —— 這能避免兩個人做同樣的事。
  3. Fork 儲存庫,在一個分支上完成修改。
  4. 送出 Pull Request,並在描述裡引用這個 Issue 編號。

研究方向

先定位 footer 和 statusline 的設定與渲染入口,然後追蹤目前路徑與分支值的截斷及持久化方式。驗證現有的從開頭截斷行為,並確定每個項目的開頭、結尾或中間偏好應放在哪裡。完成的標準是兩個介面都能保留該設定,並在窄終端中顯示要求的路徑或分支末尾部分,同時使用省略號。

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

評估

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

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

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