Hacktoberfest 2026 : les issues que les mainteneurs ont marquées pour octobre, ouvertes et accessibles aux débutants. Parcourir les issues Hacktoberfest

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

Fermée
#3,359 4 commentaires 0 réactions 0 personnes assignées Voir sur GitHub

Une pull request liée a déjà été fusionnée.

  • #3360 par @xsbsy-hzbyp — fusionnée

Évaluation

Difficulté
3/5
Temps estimé
1-2 jours
Accessibilité débutants
70/100
Type d'issue
Bug
Clarté
Plutôt claire
Activité
Active
Stack technique
lua
Domaine
tooling

Piste de recherche

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.

Rédigé par le modèle d'indexation à partir du texte de l'issue.

Description

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

Langage dominant
Lua
Étoiles
8.7k
Forks
638
Merge moyen
8 h 25 min
PR mergées (30 j)
3

Préparer son environnement

Par où commencer

  1. Lisez l'issue en entier, puis le guide de contribution du projet.
  2. Signalez en commentaire que vous la prenez — cela évite que deux personnes fassent le même travail.
  3. Forkez le dépôt et travaillez sur une branche.
  4. Ouvrez une pull request qui référence le numéro de l'issue.

Autres issues de nvim-tree/nvim-tree.lua

Toutes les issues de nvim-tree/nvim-tree.lua

Issues similaires

Plus d'issues Lua

Recevez les nouvelles issues par e-mail

Un résumé court des issues GitHub adaptées aux débutants.