1
0
Fork 0

nvim: stop reading config if nvim is too old

This commit is contained in:
tastytea 2022-08-15 13:25:38 +02:00
parent 9c00db7620
commit 27dedd8400
Signed by: tastytea
SSH Key Fingerprint: SHA256:FBkvrOlhq5use1XEttyUGT4bUTDVA1ar9SgIc9P03cM
1 changed files with 7 additions and 2 deletions

View File

@ -1,5 +1,10 @@
if vim.fn.has('nvim-0.7.0') == 0 then
print("Old version detected. Some stuff will probably not work.")
local version_required = 'nvim-0.7.0'
-- 0.7.0 features we need:
-- - autocommands in Lua
-- - bind key mappings directly to Lua functions
if vim.fn.has(version_required) == 0 then
print("💥 need " .. version_required .. ", config files will NOT be read!")
return nil
end
require('my/plugins')