Ubuntu 20.04 在装置 Neovim 的时候,间接应用 sudo apt-get install neovim
,会装置比拟老的版本,而老版本的 Neovim 不能应用 Lua 进行配置,所以,须要装置较新版本。
参考 https://github.com/neovim/neo...
如果要装置 stable 版本,运行:
sudo add-apt-repository ppa:neovim-ppa/stable
如果要装置 unstable 版本,运行:
sudo add-apt-repository ppa:neovim-ppa/unstable
之后更新 apt 源并装置即可
sudo apt-get updatesudo apt-get install neovim
查看 Neovim 版本号确定装置版本无误
❯ nvim --versionNVIM v0.6.1Build type: ReleaseLuaJIT 2.1.0-beta3Compiled by team+vim@tracker.debian.orgFeatures: +acl +iconv +tuiSee ":help feature-compile" system vimrc file: "$VIM/sysinit.vim" fall-back for $VIM: "/usr/share/nvim"Run :checkhealth for more info