summaryrefslogtreecommitdiff
path: root/dot_config/nvim/init.lua
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--dot_config/nvim/init.lua52
1 files changed, 22 insertions, 30 deletions
diff --git a/dot_config/nvim/init.lua b/dot_config/nvim/init.lua
index 4dcf175..ec4a55e 100644
--- a/dot_config/nvim/init.lua
+++ b/dot_config/nvim/init.lua
@@ -1,34 +1,26 @@
--- allow running code unconditionally before or after plugins / noplugins are loaded
+-- [nfnl] Compiled from init.fnl by https://github.com/Olical/nfnl, do not edit.
local function doif(path)
- local cpath = vim.fn.stdpath 'config' .. '/'
- if vim.fn.filereadable(cpath .. path) > 0 then
- dofile(cpath .. path)
- end
+ local path0 = (vim.fn.stdpath("config") .. "/" .. path)
+ local do_3f = (0 < vim.fn.filereadable(path0))
+ if do_3f then
+ return dofile(path0)
+ else
+ return nil
+ end
end
-
--- leader, localleader, options
-doif 'pre.lua'
-
--- plugins
-if vim.fn.executable 'git' == 0 then
- doif 'noplugins.lua'
+doif("pre.lua")
+if (0 == vim.fn.executable("git")) then
+ doif("noplugins.lua")
else
- local lazypath = vim.fn.stdpath("data") .. "/lazy/lazy.nvim"
- if not vim.loop.fs_stat(lazypath) then
- vim.fn.system({
- "git",
- "clone",
- "--filter=blob:none",
- "https://github.com/folke/lazy.nvim.git",
- "--branch=stable", -- latest stable release
- lazypath,
- })
- end
- vim.opt.rtp:prepend(lazypath)
- require 'lazy'.setup("plugins", {})
- require 'bindings'
- vim.cmd [[colorscheme starlight]]
+ local lazypath = (vim.fn.stdpath("data") .. "/lazy/lazy.nvim")
+ local fstat = vim.loop.fs_stat(lazypath)
+ if not fstat then
+ vim.fn.system({"git", "clone", "--filter=blob:none", "https://github.com/folke/lazy.nvim.git", "--branch=stable", lazypath})
+ else
+ end
+ do end (vim.opt.rtp):prepend(lazypath)
+ do end (require("lazy")).setup("plugins", {})
+ require("bindings")
+ vim.cmd("colorscheme starlight")
end
-
--- custom file associations etc
-doif 'post.lua'
+return doif("post.lua")