From 6770808bec1ffcada425ae514747f9380e3d3b8d Mon Sep 17 00:00:00 2001 From: kylo252 <59826753+kylo252@users.noreply.github.com> Date: Mon, 6 Dec 2021 17:04:46 +0100 Subject: feat: full compatibility with neovim v0.6 (#2037) --- utils/installer/install.sh | 12 ++++++++++++ 1 file changed, 12 insertions(+) (limited to 'utils/installer/install.sh') diff --git a/utils/installer/install.sh b/utils/installer/install.sh index b6b7bc31..88c3e550 100755 --- a/utils/installer/install.sh +++ b/utils/installer/install.sh @@ -174,6 +174,17 @@ function print_missing_dep_msg() { fi } +function check_neovim_min_version() { + # TODO: consider locking the requirement to 0.6+ + local verify_version_cmd='if !has("nvim-0.5.1") | cquit | else | quit | endif' + + # exit with an error if min_version not found + if ! nvim --headless -u NONE -c "$verify_version_cmd"; then + echo "[ERROR]: LunarVim requires at least Neovim v0.5.1 or higher" + exit 1 + fi +} + function check_system_deps() { if ! command -v git &>/dev/null; then print_missing_dep_msg "git" @@ -183,6 +194,7 @@ function check_system_deps() { print_missing_dep_msg "neovim" exit 1 fi + check_neovim_min_version } function __install_nodejs_deps_npm() { -- cgit v1.2.3