2023-01-20 17:57:58 +00:00
|
|
|
local lazypath = vim.fn.stdpath("data") .. "/lazy/lazy.nvim"
|
|
|
|
if not vim.loop.fs_stat(lazypath) then
|
|
|
|
vim.fn.system({
|
2022-10-01 11:46:18 +00:00
|
|
|
"git",
|
|
|
|
"clone",
|
2023-01-20 17:57:58 +00:00
|
|
|
"--filter=blob:none",
|
|
|
|
"https://github.com/folke/lazy.nvim.git",
|
|
|
|
"--branch=stable", -- latest stable release
|
|
|
|
lazypath,
|
2022-10-01 11:46:18 +00:00
|
|
|
})
|
|
|
|
end
|
2023-01-20 17:57:58 +00:00
|
|
|
vim.opt.rtp:prepend(lazypath)
|
|
|
|
vim.g.mapleader = " "
|
|
|
|
vim.g.maplocalleader = " "
|
2022-10-01 11:46:18 +00:00
|
|
|
|
2023-01-21 11:35:30 +00:00
|
|
|
local lazy_opts = {
|
|
|
|
ui = {
|
|
|
|
border = "rounded",
|
|
|
|
},
|
|
|
|
}
|
|
|
|
|
2023-10-01 15:38:01 +00:00
|
|
|
local uv = vim.loop
|
|
|
|
local function readFile(path)
|
|
|
|
local fd = uv.fs_open(path, "r", 438)
|
|
|
|
if fd == nil then
|
|
|
|
return nil
|
|
|
|
end
|
|
|
|
local stat = uv.fs_fstat(fd)
|
|
|
|
if fd == nil then
|
|
|
|
return nil
|
|
|
|
end
|
|
|
|
local data = uv.fs_read(fd, stat.size, 0)
|
|
|
|
if data == nil then
|
|
|
|
return nil
|
|
|
|
end
|
|
|
|
assert(uv.fs_close(fd))
|
2023-09-28 16:17:05 +00:00
|
|
|
|
2023-10-01 15:38:01 +00:00
|
|
|
return data
|
|
|
|
end
|
2023-09-28 16:17:05 +00:00
|
|
|
|
2023-10-01 15:38:01 +00:00
|
|
|
local projects = function()
|
|
|
|
local data = readFile(os.getenv("HOME") .. "/.config/nvim/neovim-projects.json")
|
|
|
|
if data then
|
|
|
|
return vim.json.decode(data)
|
|
|
|
else
|
|
|
|
return {}
|
|
|
|
end
|
2023-09-28 16:17:05 +00:00
|
|
|
end
|
|
|
|
|
2023-04-12 18:09:30 +00:00
|
|
|
require("lazy").setup({
|
2023-01-20 17:57:58 +00:00
|
|
|
-- Colorschemes
|
|
|
|
{
|
|
|
|
"folke/tokyonight.nvim",
|
|
|
|
lazy = false,
|
|
|
|
priority = 1000,
|
|
|
|
config = function()
|
|
|
|
require("tokyonight").setup({
|
|
|
|
style = "moon",
|
|
|
|
styles = {
|
|
|
|
sidebars = "normal",
|
|
|
|
floats = "normal",
|
|
|
|
},
|
2023-03-09 19:08:35 +00:00
|
|
|
on_colors = function(colors)
|
|
|
|
colors.error = "#ff966c"
|
|
|
|
colors.gitSigns.add = "#c3e88d"
|
|
|
|
colors.gitSigns.change = "#779be9"
|
|
|
|
end,
|
2023-01-20 17:57:58 +00:00
|
|
|
})
|
2022-10-01 11:46:18 +00:00
|
|
|
end,
|
|
|
|
},
|
2023-03-12 14:58:25 +00:00
|
|
|
{
|
|
|
|
"projekt0n/github-nvim-theme",
|
|
|
|
lazy = false,
|
2023-04-05 19:25:04 +00:00
|
|
|
priority = 1000,
|
2023-03-12 14:58:25 +00:00
|
|
|
config = function()
|
2023-05-25 16:54:11 +00:00
|
|
|
local options = {
|
|
|
|
darken = {
|
|
|
|
floats = false,
|
|
|
|
sidebars = {
|
2023-10-20 15:45:42 +00:00
|
|
|
enabled = false,
|
2023-05-25 16:54:11 +00:00
|
|
|
},
|
2023-03-12 14:58:25 +00:00
|
|
|
},
|
2024-02-03 16:59:40 +00:00
|
|
|
styles = {
|
|
|
|
comments = "italic",
|
|
|
|
keywords = "italic",
|
|
|
|
},
|
2023-05-25 16:54:11 +00:00
|
|
|
}
|
|
|
|
local specs = {
|
|
|
|
github_dark_dimmed = {
|
2024-02-03 16:59:40 +00:00
|
|
|
syntax = {
|
|
|
|
builtin1 = "#96d0ff",
|
|
|
|
},
|
2023-05-25 16:54:11 +00:00
|
|
|
diagnostic = {
|
|
|
|
error = "#dd6861",
|
|
|
|
},
|
|
|
|
},
|
|
|
|
}
|
|
|
|
require("github-theme").setup({ options = options, specs = specs })
|
2024-03-17 17:25:34 +00:00
|
|
|
end,
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"rose-pine/neovim",
|
|
|
|
name = "rose-pine",
|
|
|
|
lazy = false,
|
|
|
|
config = function()
|
|
|
|
vim.cmd("colorscheme rose-pine-moon")
|
2023-03-12 14:58:25 +00:00
|
|
|
end,
|
|
|
|
},
|
|
|
|
|
2022-10-01 11:46:18 +00:00
|
|
|
-- Plugins
|
2023-01-28 17:14:14 +00:00
|
|
|
{ "nvim-lua/plenary.nvim", lazy = true },
|
2023-02-04 13:59:28 +00:00
|
|
|
{ "echasnovski/mini.starter", lazy = "VimEnter", version = "*" },
|
2023-01-20 17:57:58 +00:00
|
|
|
{ "windwp/nvim-autopairs" },
|
|
|
|
{ "numToStr/Comment.nvim", version = "v0.*" },
|
|
|
|
{ "JoosepAlviste/nvim-ts-context-commentstring" },
|
2023-02-04 13:59:28 +00:00
|
|
|
{ "nvim-tree/nvim-web-devicons", lazy = true },
|
2023-10-09 16:37:58 +00:00
|
|
|
{ "akinsho/bufferline.nvim", event = "VeryLazy", version = "v4.*" },
|
2023-01-20 17:57:58 +00:00
|
|
|
{ "moll/vim-bbye" },
|
2023-01-28 17:14:14 +00:00
|
|
|
{ "nvim-lualine/lualine.nvim", event = "VeryLazy" },
|
2023-10-09 17:50:41 +00:00
|
|
|
{ "lukas-reineke/indent-blankline.nvim", event = "BufReadPost", main = "ibl" },
|
2023-01-28 17:14:14 +00:00
|
|
|
{ "nvim-zh/auto-save.nvim", event = "BufReadPost" },
|
2023-09-22 16:55:08 +00:00
|
|
|
{
|
|
|
|
"folke/noice.nvim",
|
|
|
|
event = "VeryLazy",
|
|
|
|
dependencies = {
|
|
|
|
"MunifTanjim/nui.nvim",
|
|
|
|
},
|
|
|
|
},
|
2023-01-20 17:57:58 +00:00
|
|
|
{ "romgrk/fzy-lua-native" },
|
2024-02-16 15:37:22 +00:00
|
|
|
{ "mg979/vim-visual-multi" },
|
2023-09-28 16:17:05 +00:00
|
|
|
{
|
|
|
|
"coffebar/neovim-project",
|
|
|
|
opts = {
|
|
|
|
projects = projects(),
|
|
|
|
last_session_on_startup = false,
|
|
|
|
},
|
|
|
|
init = function()
|
|
|
|
vim.opt.sessionoptions:append("globals")
|
|
|
|
end,
|
|
|
|
dependencies = {
|
|
|
|
{ "Shatur/neovim-session-manager" },
|
|
|
|
},
|
|
|
|
priority = 100,
|
|
|
|
},
|
2023-01-28 17:14:14 +00:00
|
|
|
{ "nvim-treesitter/nvim-treesitter", event = "BufReadPost" },
|
2023-01-20 17:57:58 +00:00
|
|
|
{
|
2022-10-01 11:46:18 +00:00
|
|
|
"nvim-neo-tree/neo-tree.nvim",
|
2023-10-08 18:01:33 +00:00
|
|
|
version = "v3.x",
|
2023-01-20 17:57:58 +00:00
|
|
|
dependencies = { "MunifTanjim/nui.nvim" },
|
|
|
|
},
|
2023-01-28 17:14:14 +00:00
|
|
|
{ "taybart/b64.nvim", event = "VeryLazy" },
|
2023-02-16 18:48:08 +00:00
|
|
|
{ "echasnovski/mini.align", event = "VeryLazy", version = "*" },
|
2023-03-11 15:29:00 +00:00
|
|
|
{ "tenxsoydev/karen-yank.nvim", event = "VeryLazy", config = true },
|
2023-04-05 19:25:04 +00:00
|
|
|
{
|
|
|
|
"ggandor/leap.nvim",
|
|
|
|
version = "*",
|
|
|
|
config = function()
|
|
|
|
require("leap").add_default_mappings()
|
2024-03-29 16:58:08 +00:00
|
|
|
vim.api.nvim_set_hl(0, "LeapBackdrop", { link = "Comment" })
|
2023-04-05 19:25:04 +00:00
|
|
|
end,
|
|
|
|
},
|
2023-04-09 16:13:55 +00:00
|
|
|
{
|
|
|
|
"knubie/vim-kitty-navigator",
|
|
|
|
version = "*",
|
|
|
|
build = "cp ./*.py ~/.config/kitty/",
|
|
|
|
},
|
2022-10-01 11:46:18 +00:00
|
|
|
|
|
|
|
-- cmp plugins
|
2023-01-28 17:14:14 +00:00
|
|
|
{
|
|
|
|
"hrsh7th/nvim-cmp",
|
|
|
|
event = "InsertEnter",
|
|
|
|
dependencies = {
|
|
|
|
"hrsh7th/cmp-buffer",
|
|
|
|
"hrsh7th/cmp-path",
|
|
|
|
"saadparwaiz1/cmp_luasnip",
|
|
|
|
"hrsh7th/cmp-nvim-lsp",
|
|
|
|
},
|
|
|
|
},
|
2024-02-12 19:46:40 +00:00
|
|
|
-- {
|
|
|
|
-- "Exafunction/codeium.nvim",
|
|
|
|
-- event = "BufEnter",
|
|
|
|
-- },
|
2022-10-01 11:46:18 +00:00
|
|
|
|
2022-10-12 14:02:54 +00:00
|
|
|
-- Snippets
|
2023-10-08 18:01:33 +00:00
|
|
|
{ "L3MON4D3/LuaSnip", version = "v2.*", event = "InsertEnter" },
|
2023-01-20 17:57:58 +00:00
|
|
|
{ "rafamadriz/friendly-snippets" },
|
2022-10-01 11:46:18 +00:00
|
|
|
|
|
|
|
-- LSP
|
2023-02-15 19:26:06 +00:00
|
|
|
{ "neovim/nvim-lspconfig", event = "BufReadPre" },
|
2023-01-20 17:57:58 +00:00
|
|
|
{ "williamboman/mason.nvim" },
|
|
|
|
{ "williamboman/mason-lspconfig.nvim" },
|
2023-10-14 11:56:59 +00:00
|
|
|
{ "nvimtools/none-ls.nvim", event = "BufReadPre" },
|
2023-01-28 17:14:14 +00:00
|
|
|
{ "RRethy/vim-illuminate", event = "BufReadPost" },
|
2024-04-13 17:03:34 +00:00
|
|
|
{ "folke/trouble.nvim", branch = "dev" },
|
2023-07-19 15:57:14 +00:00
|
|
|
{ "glepnir/lspsaga.nvim", event = "BufRead" },
|
2023-01-20 17:57:58 +00:00
|
|
|
{ "arkav/lualine-lsp-progress" },
|
2022-10-01 11:46:18 +00:00
|
|
|
|
|
|
|
-- Telescope
|
2023-01-28 17:14:14 +00:00
|
|
|
{ "nvim-telescope/telescope.nvim", cmd = "Telescope" },
|
2023-01-20 17:57:58 +00:00
|
|
|
{ "nvim-telescope/telescope-ui-select.nvim" },
|
2023-02-15 19:26:06 +00:00
|
|
|
{ "nvim-telescope/telescope-fzf-native.nvim", build = "make" },
|
2022-10-01 11:46:18 +00:00
|
|
|
|
|
|
|
-- Git
|
2023-01-28 17:14:14 +00:00
|
|
|
{ "lewis6991/gitsigns.nvim", event = "BufReadPre", version = "v0.*" },
|
2023-01-20 17:57:58 +00:00
|
|
|
{ "sindrets/diffview.nvim" },
|
|
|
|
{ "f-person/git-blame.nvim" },
|
2022-10-01 11:46:18 +00:00
|
|
|
|
2023-11-03 17:48:15 +00:00
|
|
|
-- YAML
|
|
|
|
{
|
|
|
|
"someone-stole-my-name/yaml-companion.nvim",
|
|
|
|
ft = { "yaml" },
|
|
|
|
opts = {
|
|
|
|
lspconfig = {
|
|
|
|
settings = {
|
|
|
|
redhat = {
|
|
|
|
telemetry = {
|
|
|
|
enabled = false,
|
|
|
|
},
|
|
|
|
},
|
|
|
|
-- yaml = {
|
|
|
|
-- schemas = {
|
|
|
|
-- ["https://custom/github-workflow.json"] = "/.github/workflows/*",
|
|
|
|
-- },
|
|
|
|
-- },
|
|
|
|
},
|
|
|
|
},
|
|
|
|
},
|
|
|
|
config = function(_, opts)
|
|
|
|
local cfg = require("yaml-companion").setup(opts)
|
|
|
|
require("lspconfig")["yamlls"].setup(cfg)
|
|
|
|
end,
|
|
|
|
},
|
|
|
|
|
2022-10-01 11:46:18 +00:00
|
|
|
-- DAP
|
2023-01-28 17:14:14 +00:00
|
|
|
{ "mfussenegger/nvim-dap", event = "VeryLazy", version = "0.*" },
|
2024-03-22 19:24:02 +00:00
|
|
|
{ "rcarriga/nvim-dap-ui", event = "VeryLazy", version = "v4.*" },
|
2023-01-28 17:14:14 +00:00
|
|
|
{ "theHamsta/nvim-dap-virtual-text", event = "VeryLazy" },
|
2022-10-01 11:46:18 +00:00
|
|
|
|
2024-02-10 15:15:03 +00:00
|
|
|
-- Python
|
|
|
|
{
|
|
|
|
"linux-cultist/venv-selector.nvim",
|
|
|
|
dependencies = {
|
|
|
|
"mfussenegger/nvim-dap-python",
|
|
|
|
},
|
|
|
|
opts = {
|
|
|
|
dap_enabled = true,
|
|
|
|
},
|
|
|
|
event = "VeryLazy",
|
|
|
|
},
|
|
|
|
|
2022-10-12 14:02:54 +00:00
|
|
|
-- Go
|
2023-01-20 17:57:58 +00:00
|
|
|
{
|
2023-04-29 15:09:28 +00:00
|
|
|
"ray-x/go.nvim",
|
|
|
|
dependencies = {
|
|
|
|
"ray-x/guihua.lua",
|
|
|
|
build = "cd lua/fzy && make",
|
|
|
|
},
|
|
|
|
event = { "CmdlineEnter" },
|
|
|
|
ft = { "go", "gomod" },
|
2023-01-20 17:57:58 +00:00
|
|
|
},
|
2024-02-10 15:15:03 +00:00
|
|
|
|
|
|
|
-- Testing
|
2024-02-03 15:22:54 +00:00
|
|
|
{
|
|
|
|
"nvim-neotest/neotest",
|
|
|
|
dependencies = {
|
|
|
|
"nvim-neotest/neotest-go",
|
2024-03-17 17:25:34 +00:00
|
|
|
"nvim-neotest/neotest-python",
|
2024-03-18 18:00:01 +00:00
|
|
|
"nvim-neotest/nvim-nio",
|
2024-02-03 15:22:54 +00:00
|
|
|
"antoinemadec/FixCursorHold.nvim",
|
|
|
|
},
|
|
|
|
},
|
2022-10-01 11:46:18 +00:00
|
|
|
|
2023-11-03 17:48:15 +00:00
|
|
|
-- Typescript
|
2024-02-03 15:22:54 +00:00
|
|
|
{
|
|
|
|
"pmizio/typescript-tools.nvim",
|
|
|
|
},
|
2023-11-03 17:48:15 +00:00
|
|
|
|
2022-10-12 14:02:54 +00:00
|
|
|
-- Markdown
|
2023-01-20 17:57:58 +00:00
|
|
|
{ "mzlogin/vim-markdown-toc" },
|
|
|
|
{
|
2022-10-01 11:46:18 +00:00
|
|
|
"iamcco/markdown-preview.nvim",
|
2023-12-12 19:21:45 +00:00
|
|
|
build = function()
|
|
|
|
vim.fn["mkdp#util#install"]()
|
|
|
|
end,
|
2023-01-20 17:57:58 +00:00
|
|
|
init = function()
|
2022-10-01 11:46:18 +00:00
|
|
|
vim.g.mkdp_filetypes = { "markdown" }
|
|
|
|
end,
|
|
|
|
ft = { "markdown" },
|
2023-01-20 17:57:58 +00:00
|
|
|
},
|
2023-07-03 17:16:19 +00:00
|
|
|
|
2024-02-12 19:46:40 +00:00
|
|
|
-- Copilot
|
|
|
|
{
|
|
|
|
"zbirenbaum/copilot.lua",
|
|
|
|
cmd = "Copilot",
|
|
|
|
event = "InsertEnter",
|
|
|
|
},
|
|
|
|
{ "zbirenbaum/copilot-cmp" },
|
|
|
|
{ "AndreM222/copilot-lualine" },
|
|
|
|
{
|
|
|
|
"copilotc-nvim/copilotchat.nvim",
|
2024-03-17 17:25:34 +00:00
|
|
|
branch = "canary",
|
2024-02-12 19:46:40 +00:00
|
|
|
event = "VeryLazy",
|
|
|
|
},
|
|
|
|
|
2023-07-03 17:16:19 +00:00
|
|
|
-- Folding
|
|
|
|
{
|
|
|
|
"kevinhwang91/nvim-ufo",
|
|
|
|
dependencies = {
|
|
|
|
"kevinhwang91/promise-async",
|
|
|
|
{
|
|
|
|
"luukvbaal/statuscol.nvim",
|
|
|
|
config = function()
|
|
|
|
local builtin = require("statuscol.builtin")
|
|
|
|
require("statuscol").setup({
|
|
|
|
relculright = true,
|
|
|
|
segments = {
|
|
|
|
{
|
|
|
|
text = {
|
|
|
|
builtin.foldfunc,
|
|
|
|
},
|
|
|
|
click = "v:lua.ScFa",
|
|
|
|
},
|
|
|
|
{ text = { "%s" }, click = "v:lua.ScSa" },
|
|
|
|
{ text = { builtin.lnumfunc, " " }, click = "v:lua.ScLa" },
|
|
|
|
},
|
|
|
|
})
|
|
|
|
end,
|
|
|
|
},
|
|
|
|
},
|
|
|
|
},
|
2024-03-17 17:25:34 +00:00
|
|
|
|
|
|
|
{ "robbles/logstash.vim" },
|
2023-01-21 11:35:30 +00:00
|
|
|
}, lazy_opts)
|