/spellfile.nvim

🌕 Port of spellfile.vim to Lua without depending on netrw

Primary LanguageLuaGNU General Public License v3.0GPL-3.0

spellfile.nvim Tests StyLua

Alternative for Vim's native spellfile.vim written in Lua and with no dependency on netrw.

Context

It looks like that nice feature of Vim/Neovim that automatically downloads missing spell files (e.g. on :set spell spelllang=pt) depends entirely on netwr:

Native spellfile.vim works using a SpellFileMissing auto command, and spellfile.nvim:

  • has no other dependency than Neovim
  • uses the same autocmd for seamless integration

You can see it working (without changing your config) by cloning this repo and:

$ nvim -u tests/init.lua

From there, try setting a language that is not installed, e.g. :set spell spelllang=pt.

Install

{ "cuducos/spellfile.nvim" }
use { "cuducos/spellfile.nvim" }

With vim-plug:

Plug 'cuducos/spellfile.nvim'

Tests

$ nvim --headless -u tests/init.lua -c "PlenaryBustedDirectory tests/ { minimal_init = 'tests/init.lua' }"