From 78111e1da6b36893e76ea217f0531ee1729c9718 Mon Sep 17 00:00:00 2001 From: Crony Akatsuki Date: Mon, 20 Oct 2025 15:11:39 +0200 Subject: [PATCH] feat(plugins): setup lazy.nvim --- lazy-lock.json | 4 ++++ lua/config/lazy.lua | 31 +++++++++++++++++++++++++++++++ 2 files changed, 35 insertions(+) create mode 100644 lazy-lock.json create mode 100644 lua/config/lazy.lua diff --git a/lazy-lock.json b/lazy-lock.json new file mode 100644 index 0000000..5741eb9 --- /dev/null +++ b/lazy-lock.json @@ -0,0 +1,4 @@ +{ + "gruvbox.nvim": { "branch": "main", "commit": "5e0a460d8e0f7f669c158dedd5f9ae2bcac31437" }, + "lazy.nvim": { "branch": "main", "commit": "1ea3c4085785f460fb0e46d2fe1ee895f5f9e7c1" } +} diff --git a/lua/config/lazy.lua b/lua/config/lazy.lua new file mode 100644 index 0000000..a2a92ab --- /dev/null +++ b/lua/config/lazy.lua @@ -0,0 +1,31 @@ +-- Bootstrap lazy.nvim +local lazypath = vim.fn.stdpath("data") .. "/lazy/lazy.nvim" +if not (vim.uv or vim.loop).fs_stat(lazypath) then + local lazyrepo = "https://github.com/folke/lazy.nvim.git" + local out = vim.fn.system({ "git", "clone", "--filter=blob:none", "--branch=stable", lazyrepo, lazypath }) + if vim.v.shell_error ~= 0 then + vim.api.nvim_echo({ + { "Failed to clone lazy.nvim:\n", "ErrorMsg" }, + { out, "WarningMsg" }, + { "\nPress any key to exit..." }, + }, true, {}) + vim.fn.getchar() + os.exit(1) + end +end +vim.opt.rtp:prepend(lazypath) + +--setup lazy.nvim +require("lazy").setup({ + spec = { + -- import plugins from specific directory + { import = "plugins" }, + }, + -- setup correct colorscheme + install = { colorscheme = { "gruvbox"} }, + -- automatically check for plugin updates + checker = { enabled = true }, + rocks = { + enabled = false + }, +})