Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/lambdalisue/vim-nerdfont
👓 Fundemental plugin to handle Nerd Fonts in Vim
https://github.com/lambdalisue/vim-nerdfont
devicons neovim nerdfont vim
Last synced: 4 days ago
JSON representation
👓 Fundemental plugin to handle Nerd Fonts in Vim
- Host: GitHub
- URL: https://github.com/lambdalisue/vim-nerdfont
- Owner: lambdalisue
- License: mit
- Created: 2020-07-28T11:14:21.000Z (over 4 years ago)
- Default Branch: master
- Last Pushed: 2024-11-10T06:49:55.000Z (about 2 months ago)
- Last Synced: 2024-12-21T05:07:43.528Z (11 days ago)
- Topics: devicons, neovim, nerdfont, vim
- Language: Vim Script
- Homepage:
- Size: 91.8 KB
- Stars: 144
- Watchers: 6
- Forks: 15
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# 👓 nerdfont.vim
![Support Vim 8.2.5136 or above](https://img.shields.io/badge/support-Vim%208.2.5136%20or%20above-yellowgreen.svg)
![Support Neovim 0.4.4 or above](https://img.shields.io/badge/support-Neovim%200.4.4%20or%20above-yellowgreen.svg)
[![MIT License](https://img.shields.io/badge/license-MIT-blue.svg)](LICENSE)
[![Doc](https://img.shields.io/badge/doc-%3Ah%20nerdfont-orange.svg)](doc/nerdfont.txt)[![reviewdog](https://github.com/lambdalisue/nerdfont.vim/workflows/reviewdog/badge.svg)](https://github.com/lambdalisue/nerdfont.vim/actions?query=workflow%3Areviewdog)
[![Vim](https://github.com/lambdalisue/vim-nerdfont/actions/workflows/vim.yml/badge.svg)](https://github.com/lambdalisue/vim-nerdfont/actions/workflows/vim.yml)
[![Neovim](https://github.com/lambdalisue/vim-nerdfont/actions/workflows/neovim.yml/badge.svg)](https://github.com/lambdalisue/vim-nerdfont/actions/workflows/neovim.yml)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.[vim-devicons]: https://github.com/ryanoasis/vim-devicons
[nerd fonts]: https://github.com/ryanoasis/nerd-fonts![](https://user-images.githubusercontent.com/546312/88701008-6c1c5980-d144-11ea-8d6b-d4f4290274a6.png)
_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:```vim
echo nerdfont#find()

```Or specify a path to find a glyph for a particular path like:
```vim
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:```vim
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`) | [`assets/json/extension.json`](./assets/json/extension.json) |
| Want to add new exact name (e.g. `Makefile`) | [`assets/json/basename.json`](./assets/json/basename.json) |
| Want to add new complex pattern (e.g. `.*/bin/.*$`) | [`assets/json/pattern.json`](./assets/json/pattern.json) |## Integrations
See [Integration section](https://github.com/lambdalisue/nerdfont.vim/wiki#integrations) of Wiki.
## License
The glyph mappings has copied from [vim-devicons][] thus the part follow the license of [vim-devicons][] ([LICENSE.vim-devicons](./LICENSE.vim-devicon)).
Other parts are MIT license explained in [LICENSE](./LICENSE).