chg: Use the new recommended format for lazy.nvim
This commit is contained in:
parent
1b1f90576e
commit
bb13571b57
4 changed files with 57 additions and 50 deletions
|
@ -36,7 +36,7 @@ set.spell = true
|
||||||
-- Enable mouse support
|
-- Enable mouse support
|
||||||
set.mouse = 'n'
|
set.mouse = 'n'
|
||||||
-- Enable programming dictionary
|
-- Enable programming dictionary
|
||||||
set.spelllang = { "en", "programming" }
|
set.spelllang = { "en", "programming", "en-academic" }
|
||||||
|
|
||||||
-- Disable unused plugins
|
-- Disable unused plugins
|
||||||
g.loaded_perl_provider = 0
|
g.loaded_perl_provider = 0
|
||||||
|
|
|
@ -1,20 +1,23 @@
|
||||||
-- Automatically bootstrap lazy.nvim
|
-- Automatically bootstrap lazy.nvim
|
||||||
local lazypath = vim.fn.stdpath("data") .. "/lazy/lazy.nvim"
|
local lazypath = vim.fn.stdpath("data") .. "/lazy/lazy.nvim"
|
||||||
if not vim.loop.fs_stat(lazypath) then
|
if not (vim.uv or vim.loop).fs_stat(lazypath) then
|
||||||
vim.fn.system({
|
local lazyrepo = "https://github.com/folke/lazy.nvim.git"
|
||||||
"git",
|
local out = vim.fn.system({ "git", "clone", "--filter=blob:none", "--branch=stable", lazyrepo, lazypath })
|
||||||
"clone",
|
if vim.v.shell_error ~= 0 then
|
||||||
"--filter=blob:none",
|
vim.api.nvim_echo({
|
||||||
"https://github.com/folke/lazy.nvim.git",
|
{ "Failed to clone lazy.nvim:\n", "ErrorMsg" },
|
||||||
"--branch=stable", -- latest stable release
|
{ out, "WarningMsg" },
|
||||||
lazypath,
|
{ "\nPress any key to exit..." },
|
||||||
})
|
}, true, {})
|
||||||
|
vim.fn.getchar()
|
||||||
|
os.exit(1)
|
||||||
|
end
|
||||||
end
|
end
|
||||||
vim.opt.rtp:prepend(lazypath)
|
vim.opt.rtp:prepend(lazypath)
|
||||||
|
|
||||||
-- Load plugin via paq-nvim
|
-- Load plugin via paq-nvim
|
||||||
require("lazy").setup(
|
require("lazy").setup({
|
||||||
{
|
spec = {
|
||||||
-- Use lualine for statusbar
|
-- Use lualine for statusbar
|
||||||
"nvim-lualine/lualine.nvim",
|
"nvim-lualine/lualine.nvim",
|
||||||
"nvim-tree/nvim-web-devicons",
|
"nvim-tree/nvim-web-devicons",
|
||||||
|
@ -49,6 +52,8 @@ require("lazy").setup(
|
||||||
"SirVer/ultisnips", -- For snippets
|
"SirVer/ultisnips", -- For snippets
|
||||||
-- Support programming terms
|
-- Support programming terms
|
||||||
{ "psliwka/vim-dirtytalk", build = ":DirtytalkUpdate" },
|
{ "psliwka/vim-dirtytalk", build = ":DirtytalkUpdate" },
|
||||||
|
-- Support academic terms
|
||||||
|
{ "ficcdaf/academic.nvim", build = ":AcademicBuild" },
|
||||||
-- vim-moonfly theme
|
-- vim-moonfly theme
|
||||||
{ "bluz71/vim-moonfly-colors", as = "moonfly" },
|
{ "bluz71/vim-moonfly-colors", as = "moonfly" },
|
||||||
-- Rust tools
|
-- Rust tools
|
||||||
|
@ -77,14 +82,12 @@ require("lazy").setup(
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"felpafel/inlay-hint.nvim",
|
"felpafel/inlay-hint.nvim",
|
||||||
version = "1",
|
|
||||||
event = "LspAttach",
|
event = "LspAttach",
|
||||||
config = true,
|
config = true,
|
||||||
},
|
},
|
||||||
"dvrlabs/takeout.nvim",
|
"dvrlabs/takeout.nvim",
|
||||||
},
|
},
|
||||||
{
|
lockfile = vim.fn.stdpath("config") .. "/config/lazy-lock.json",
|
||||||
lockfile = vim.fn.stdpath("config") .. "/config/lazy-lock.json",
|
install = { missing = true, colorscheme = { "habamax" } },
|
||||||
install = { missing = true },
|
checker = { enabled = true },
|
||||||
}
|
})
|
||||||
)
|
|
||||||
|
|
|
@ -1,20 +1,23 @@
|
||||||
-- Automatically bootstrap lazy.nvim
|
-- Automatically bootstrap lazy.nvim
|
||||||
local lazypath = vim.fn.stdpath("data") .. "/lazy/lazy.nvim"
|
local lazypath = vim.fn.stdpath("data") .. "/lazy/lazy.nvim"
|
||||||
if not vim.loop.fs_stat(lazypath) then
|
if not (vim.uv or vim.loop).fs_stat(lazypath) then
|
||||||
vim.fn.system({
|
local lazyrepo = "https://github.com/folke/lazy.nvim.git"
|
||||||
"git",
|
local out = vim.fn.system({ "git", "clone", "--filter=blob:none", "--branch=stable", lazyrepo, lazypath })
|
||||||
"clone",
|
if vim.v.shell_error ~= 0 then
|
||||||
"--filter=blob:none",
|
vim.api.nvim_echo({
|
||||||
"https://github.com/folke/lazy.nvim.git",
|
{ "Failed to clone lazy.nvim:\n", "ErrorMsg" },
|
||||||
"--branch=stable", -- latest stable release
|
{ out, "WarningMsg" },
|
||||||
lazypath,
|
{ "\nPress any key to exit..." },
|
||||||
})
|
}, true, {})
|
||||||
|
vim.fn.getchar()
|
||||||
|
os.exit(1)
|
||||||
|
end
|
||||||
end
|
end
|
||||||
vim.opt.rtp:prepend(lazypath)
|
vim.opt.rtp:prepend(lazypath)
|
||||||
|
|
||||||
-- Load plugins via lazy.nvim
|
-- Load plugins via lazy.nvim
|
||||||
require("lazy").setup(
|
require("lazy").setup({
|
||||||
{
|
spec = {
|
||||||
-- Use lualine for statusbar
|
-- Use lualine for statusbar
|
||||||
"nvim-lualine/lualine.nvim",
|
"nvim-lualine/lualine.nvim",
|
||||||
"nvim-tree/nvim-web-devicons",
|
"nvim-tree/nvim-web-devicons",
|
||||||
|
@ -52,9 +55,8 @@ require("lazy").setup(
|
||||||
"ibhagwan/fzf-lua",
|
"ibhagwan/fzf-lua",
|
||||||
"karb94/neoscroll.nvim",
|
"karb94/neoscroll.nvim",
|
||||||
},
|
},
|
||||||
{
|
lockfile = vim.fn.stdpath("config") .. "/config/lazy-lock.json",
|
||||||
lockfile = vim.fn.stdpath("config") .. "/config/lazy-lock.json",
|
install = { missing = true, colorscheme = { "habamax" } },
|
||||||
install = { missing = true },
|
checker = { enabled = true },
|
||||||
}
|
})
|
||||||
)
|
|
||||||
|
|
||||||
|
|
|
@ -1,20 +1,23 @@
|
||||||
-- Automatically bootstrap lazy.nvim
|
-- Automatically bootstrap lazy.nvim
|
||||||
local lazypath = vim.fn.stdpath("data") .. "/lazy/lazy.nvim"
|
local lazypath = vim.fn.stdpath("data") .. "/lazy/lazy.nvim"
|
||||||
if not vim.loop.fs_stat(lazypath) then
|
if not (vim.uv or vim.loop).fs_stat(lazypath) then
|
||||||
vim.fn.system({
|
local lazyrepo = "https://github.com/folke/lazy.nvim.git"
|
||||||
"git",
|
local out = vim.fn.system({ "git", "clone", "--filter=blob:none", "--branch=stable", lazyrepo, lazypath })
|
||||||
"clone",
|
if vim.v.shell_error ~= 0 then
|
||||||
"--filter=blob:none",
|
vim.api.nvim_echo({
|
||||||
"https://github.com/folke/lazy.nvim.git",
|
{ "Failed to clone lazy.nvim:\n", "ErrorMsg" },
|
||||||
"--branch=stable", -- latest stable release
|
{ out, "WarningMsg" },
|
||||||
lazypath,
|
{ "\nPress any key to exit..." },
|
||||||
})
|
}, true, {})
|
||||||
|
vim.fn.getchar()
|
||||||
|
os.exit(1)
|
||||||
|
end
|
||||||
end
|
end
|
||||||
vim.opt.rtp:prepend(lazypath)
|
vim.opt.rtp:prepend(lazypath)
|
||||||
|
|
||||||
-- Load plugins via lazy.nvim
|
-- Load plugins via lazy.nvim
|
||||||
require("lazy").setup(
|
require("lazy").setup({
|
||||||
{
|
spec = {
|
||||||
-- Use lualine for statusbar
|
-- Use lualine for statusbar
|
||||||
"nvim-lualine/lualine.nvim",
|
"nvim-lualine/lualine.nvim",
|
||||||
"nvim-tree/nvim-web-devicons",
|
"nvim-tree/nvim-web-devicons",
|
||||||
|
@ -52,9 +55,8 @@ require("lazy").setup(
|
||||||
"ibhagwan/fzf-lua",
|
"ibhagwan/fzf-lua",
|
||||||
"karb94/neoscroll.nvim",
|
"karb94/neoscroll.nvim",
|
||||||
},
|
},
|
||||||
{
|
lockfile = vim.fn.stdpath("config") .. "/config/lazy-lock.json",
|
||||||
lockfile = vim.fn.stdpath("config") .. "/config/lazy-lock.json",
|
install = { missing = true, colorscheme = { "habamax" } },
|
||||||
install = { missing = true },
|
checker = { enabled = true },
|
||||||
}
|
})
|
||||||
)
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue