Hacktoberfest 2026: những issue maintainer đã đánh dấu cho tháng Mười, đang mở và phù hợp người mới. Xem issue Hacktoberfest

Auto re-highlight does not respect defined legacy highlight groups if new ones are default-linked.

Đang mở
#3,359 4 bình luận 0 reaction 0 người được giao Xem trên GitHub

@xsbsy-hzbyp đang làm issue này rồi.

Từ ngày 6/10/2026.

  • #3360 của @xsbsy-hzbyp — đang mở

Đánh giá

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

Hướng nghiên cứu

Start in lua/nvim-tree/appearance/init.lua around the linked re-highlight logic at line 198, and read how highlight groups are checked and linked. Verify the behavior with a defined legacy group and a new group retaining only its default link. Done means re-highlighting respects the legacy definition in that case without changing existing behavior for explicitly defined new groups.

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

Mô tả

bug reproduced
Description

If we have previously highlight default-ed a highlight group, then even after highlight clear, the current re-highlight logic would not respect legacy highlights even if they are defined, so for example, even if a colorscheme has a definition for NvimTreeGitNew, after our autocmd is run, NvimTreeGitNewIcon still links to PreProc.

Currently we only link to a legacy group if the new group is not defined and the legacy group is defined. Should we change it to "if the new group is not defined or is defined but has only the default link"?

Neovim version
NVIM v0.12.5
Operating system and version

Linux

Windows variant

No response

nvim-tree version

master

Clean room replication
none
Steps to reproduce

none

Expected behavior

No response

Actual behavior

No response

Ngôn ngữ chính
Lua
Star
8.7k
Fork
638
Merge trung bình
1 ngày 1 giờ
Pull request đã merge (30 ngày)
3

Chuẩn bị môi trường

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Issue khác của nvim-tree/nvim-tree.lua

Tất cả issue của nvim-tree/nvim-tree.lua

Issue tương tự

Thêm issue về Lua

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.