github / github/copilot-cli

/diff viewer shows only leaf filename in tab bar — ambiguous for lib.rs, mod.rs, etc.

Đang mở
#2,910 0 bình luận 1 reaction 0 người được giao Xem trên GitHub
area:terminal-rendering
Ngôn ngữ chính
Shell
Star
11.2k
Fork
1.9k
Merge trung bình
14 giờ 16 phút
Pull request đã merge (30 ngày)
6

Mô tả

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

The `/diff` viewer's file navigator tab bar shows only the leaf filename (`lib.rs`, `mod.rs`) instead of the full or distinguishing path. In Rust projects (and other ecosystems with convention-based filenames), dozens of files share the same leaf name, making it impossible to tell which file is which.

### Proposed solution

Show the full relative path — or at minimum a disambiguated path suffix — in the `/diff` file navigator tab bar.

Currently the tab label is the *only* file identifier, with no tooltip or secondary path display. If two changed files share a basename (e.g., `crates/driver/src/lib.rs` and `crates/runtime/src/lib.rs`), both tabs show `lib.rs` with no way to distinguish them.

**Suggested approach:** Show the full relative path in the tab label, or use VS Code-style automatic path disambiguation — when two tabs share a filename, append enough parent directory segments to distinguish them (e.g., `driver/src/lib.rs` vs `runtime/src/lib.rs`).

### Example prompts or workflows

1. Open a Rust workspace with multiple crates, make changes in two different `lib.rs` files, run `/diff` — both tabs show `lib.rs`, no way to know which is which.
2. Same problem with `mod.rs`, `main.rs`, `build.rs` across crates in a workspace.

### Additional context

This is especially painful in Rust where `lib.rs`, `mod.rs`, `main.rs`, and `build.rs` are convention-based names repeated across every crate in a workspace. Go (`main.go`), Python (`__init__.py`), and Java (`Application.java`) have similar patterns.

Hướng dẫn đóng góp

Mở hướng dẫn đóng góp

Hướng nghiên cứu

Bắt đầu tại thanh tab của trình điều hướng tệp /diff và tái hiện vấn đề với các tệp đã thay đổi có cùng tên cơ sở, chẳng hạn như crates/driver/src/lib.rs và crates/runtime/src/lib.rs. Xác định điểm truy cập hiện có của nhãn tab và làm cho các nhãn phân biệt được những tệp đó bằng cách hiển thị đường dẫn tương đối đầy đủ hoặc đủ để phân biệt; hoàn tất khi các tên cơ sở trùng nhau không còn mơ hồ.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Đánh giá

Công nghệ
shell
Lĩnh vực
cli
Loại issue
Tính năng
Độ khó
3/5
Thời gian dự kiến
1-2 ngày
Mức độ hoạt động
Ít trao đổi
Độ rõ ràng
Khá rõ ràng
Mức phù hợp với người mới
58/100

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.