Skip to content
master
Switch branches/tags
Go to file
Code

Files

Permalink
Failed to load latest commit information.
Type
Name
Latest commit message
Commit time
Jul 28, 2020

πŸ‘“ nerdfont.vim

Support Vim 8.1 or above Support Neovim 0.4 or above MIT License Doc

reviewdog vim neovim

A simplified version of vim-devicons which does NOT provide any 3rd party integrations in itself. In otherwords, it is a fundemental plugin to handle Nerd Fonts from Vim.

With fern.vim + fern-renderer-nerdfont.vim. All glyphs above were powered by this plugin

Usage

First of all, make sure one of Nerd Fonts is used in your Vim. After that, use nerdfont#find() function to find a glyph for the current filetype like:

echo nerdfont#find()
ξ˜‰

Or specify a path to find a glyph for a particular path like:

echo nerdfont#find(expand('~/.vimrc'))

echo nerdfont#find(expand('~/.vim'))
ξ˜“

Above automatically check if the specified path is directory. To avoid that, specify the second argument to tell if the path is directory or not like:

echo nerdfont#find(expand('~/.vimrc'), 0)

echo nerdfont#find(expand('~/.vimrc'), 1)
ξ˜“

See :help nerdfont-function to find glyphs for directory, fileformat, platform, etc.

Contribution

If you would like to add new glyph/filetype supports, see the following files

If Where
Want to add new extension (e.g. .js) autoload/nerdfont/path/extension.vim
Want to add new exact name (e.g. Makefile) autoload/nerdfont/path/basename.vim
Want to add new complex pattern (e.g. .*/bin/.*$) autoload/nerdfont/path/pattern.vim

Integrations

Name Description
glyph-palette.vim An universal palette for glyphs to highlight nicely
fern-renderer-nerdfont.vim A fern.vim plugin which use nerdfont.vim to provide fancy glyphs

License

The glyph mappings has copied from vim-devicons thus the part follow the license of vim-devicons (LICENSE.vim-devicons). Other parts are MIT license explained in LICENSE.