From ee0bd61fd56325483b90a4b08daa037ff4aaa7ad Mon Sep 17 00:00:00 2001 From: Chris Grieser <73286100+chrisgrieser@users.noreply.github.com> Date: Wed, 5 Jun 2024 00:48:19 +0200 Subject: [PATCH] chore: add nvim version requirement check --- lua/rip-substitute/init.lua | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/lua/rip-substitute/init.lua b/lua/rip-substitute/init.lua index 55c1e45..57c2b5d 100644 --- a/lua/rip-substitute/init.lua +++ b/lua/rip-substitute/init.lua @@ -1,3 +1,10 @@ +local version = vim.version() +if version.major == 0 and version.minor < 10 then + vim.notify("nvim-rip-substitute requires at least nvim 0.10.", vim.log.levels.WARN) + return +end +-------------------------------------------------------------------------------- + local M = {} -- PERF do not import submodules here, since it results in them all being loaded -- on initialization instead of lazy-loading them when needed.