nvim-tree / nvim-web-devicons

lua `fork` of vim-web-devicons for neovim
MIT License
2.02k stars 182 forks source link

set icon #176

Closed xuyastc closed 1 year ago

xuyastc commented 1 year ago

Hi,I want.zshrc_xuya_config to use the same icon as.zshrc.How should override be written?

image

The second question

image

How do I modify this?

I need you help, thanks

xuyastc commented 1 year ago

I tried to change override but it didn't work so I need you help

alex-courtis commented 1 year ago

You can set that individual file to be a clone of .zshrc via something like:

  local icon, color, cterm_color = require'nvim-web-devicons'.get_icon_colors('.zshrc')

  require('nvim-web-devicons').set_icon({
    ['.zshrc_xuya_co'] = {
      icon = icon,
      color = color,
      cterm_color = cterm_color,
      name = "Zshrc",
    }
  })