2022-01-09 03:37:18 +00:00
|
|
|
local plugin_settings = require("core.utils").load_config().plugins
|
|
|
|
local present, packer = pcall(require, plugin_settings.options.packer.init_file)
|
2021-08-12 11:58:03 +00:00
|
|
|
|
2021-08-22 07:49:15 +00:00
|
|
|
if not present then
|
2021-08-16 07:49:09 +00:00
|
|
|
return false
|
2021-07-15 15:46:45 +00:00
|
|
|
end
|
|
|
|
|
2022-01-30 07:21:46 +00:00
|
|
|
local plugins = {
|
2022-04-27 15:42:28 +00:00
|
|
|
["nvim-lua/plenary.nvim"] = {},
|
|
|
|
["lewis6991/impatient.nvim"] = {},
|
2021-09-14 02:21:35 +00:00
|
|
|
|
2022-04-27 15:42:28 +00:00
|
|
|
["wbthomason/packer.nvim"] = {
|
2021-08-16 07:49:09 +00:00
|
|
|
event = "VimEnter",
|
2022-01-30 07:21:46 +00:00
|
|
|
},
|
2021-06-01 18:28:24 +00:00
|
|
|
|
2022-04-27 15:42:28 +00:00
|
|
|
["NvChad/extensions"] = {},
|
2022-03-20 21:22:16 +00:00
|
|
|
|
2022-04-27 15:42:28 +00:00
|
|
|
["NvChad/nvim-base16.lua"] = {
|
2021-08-22 07:49:15 +00:00
|
|
|
after = "packer.nvim",
|
|
|
|
config = function()
|
|
|
|
require("colors").init()
|
|
|
|
end,
|
2022-01-30 07:21:46 +00:00
|
|
|
},
|
2021-08-22 07:49:15 +00:00
|
|
|
|
2022-04-27 15:42:28 +00:00
|
|
|
["NvChad/nvterm"] = {
|
|
|
|
config = function()
|
|
|
|
require "plugins.configs.nvterm"
|
|
|
|
end,
|
|
|
|
},
|
|
|
|
|
|
|
|
["kyazdani42/nvim-web-devicons"] = {
|
2021-08-22 07:49:15 +00:00
|
|
|
after = "nvim-base16.lua",
|
2022-04-27 15:42:28 +00:00
|
|
|
config = function()
|
|
|
|
require "plugins.configs.icons"
|
|
|
|
end,
|
2022-01-30 07:21:46 +00:00
|
|
|
},
|
2021-07-26 09:36:32 +00:00
|
|
|
|
2022-04-27 15:42:28 +00:00
|
|
|
["feline-nvim/feline.nvim"] = {
|
2021-08-17 06:42:33 +00:00
|
|
|
after = "nvim-web-devicons",
|
2022-04-27 15:42:28 +00:00
|
|
|
config = function()
|
|
|
|
require "plugins.configs.statusline"
|
|
|
|
end,
|
2022-01-30 07:21:46 +00:00
|
|
|
},
|
2021-08-22 07:49:15 +00:00
|
|
|
|
2022-04-27 15:42:28 +00:00
|
|
|
["akinsho/bufferline.nvim"] = {
|
2021-08-26 09:40:26 +00:00
|
|
|
after = "nvim-web-devicons",
|
2022-04-27 15:42:28 +00:00
|
|
|
|
2021-08-16 07:49:09 +00:00
|
|
|
setup = function()
|
2021-08-22 07:49:15 +00:00
|
|
|
require("core.mappings").bufferline()
|
2021-08-16 07:49:09 +00:00
|
|
|
end,
|
2022-04-27 15:42:28 +00:00
|
|
|
|
|
|
|
config = function()
|
|
|
|
require "plugins.configs.bufferline"
|
|
|
|
end,
|
2022-01-30 07:21:46 +00:00
|
|
|
},
|
2021-07-09 03:44:04 +00:00
|
|
|
|
2022-04-27 15:42:28 +00:00
|
|
|
["lukas-reineke/indent-blankline.nvim"] = {
|
2021-08-22 07:49:15 +00:00
|
|
|
event = "BufRead",
|
2022-04-27 15:42:28 +00:00
|
|
|
config = function()
|
|
|
|
require("plugins.configs.others").blankline()
|
|
|
|
end,
|
2022-01-30 07:21:46 +00:00
|
|
|
},
|
2021-06-27 15:29:39 +00:00
|
|
|
|
2022-04-27 15:42:28 +00:00
|
|
|
["NvChad/nvim-colorizer.lua"] = {
|
2021-08-16 07:49:09 +00:00
|
|
|
event = "BufRead",
|
2022-04-27 15:42:28 +00:00
|
|
|
config = function()
|
|
|
|
require("plugins.configs.others").colorizer()
|
|
|
|
end,
|
2022-01-30 07:21:46 +00:00
|
|
|
},
|
2021-06-01 18:28:24 +00:00
|
|
|
|
2022-04-27 15:42:28 +00:00
|
|
|
["nvim-treesitter/nvim-treesitter"] = {
|
2022-03-01 07:13:34 +00:00
|
|
|
event = { "BufRead", "BufNewFile" },
|
2022-02-23 04:09:21 +00:00
|
|
|
run = ":TSUpdate",
|
2022-04-27 15:42:28 +00:00
|
|
|
config = function()
|
|
|
|
require "plugins.configs.treesitter"
|
|
|
|
end,
|
2022-01-30 07:21:46 +00:00
|
|
|
},
|
2021-06-25 16:06:13 +00:00
|
|
|
|
2021-08-26 09:40:26 +00:00
|
|
|
-- git stuff
|
2022-04-27 15:42:28 +00:00
|
|
|
["lewis6991/gitsigns.nvim"] = {
|
2021-08-26 09:40:26 +00:00
|
|
|
opt = true,
|
2022-04-27 15:42:28 +00:00
|
|
|
config = function()
|
|
|
|
require("plugins.configs.others").gitsigns()
|
|
|
|
end,
|
2021-08-26 09:40:26 +00:00
|
|
|
setup = function()
|
|
|
|
require("core.utils").packer_lazy_load "gitsigns.nvim"
|
|
|
|
end,
|
2022-01-30 07:21:46 +00:00
|
|
|
},
|
2021-08-26 09:40:26 +00:00
|
|
|
|
2021-08-27 02:26:44 +00:00
|
|
|
-- lsp stuff
|
2021-09-10 10:10:54 +00:00
|
|
|
|
2022-04-27 15:42:28 +00:00
|
|
|
["neovim/nvim-lspconfig"] = {
|
2022-01-22 07:53:15 +00:00
|
|
|
module = "lspconfig",
|
2021-08-26 09:40:26 +00:00
|
|
|
opt = true,
|
|
|
|
setup = function()
|
2021-09-10 10:10:54 +00:00
|
|
|
require("core.utils").packer_lazy_load "nvim-lspconfig"
|
2021-10-01 14:04:18 +00:00
|
|
|
-- reload the current file so lsp actually starts for it
|
|
|
|
vim.defer_fn(function()
|
2021-10-02 05:29:23 +00:00
|
|
|
vim.cmd 'if &ft == "packer" | echo "" | else | silent! e %'
|
2021-10-01 14:04:18 +00:00
|
|
|
end, 0)
|
2021-08-26 09:40:26 +00:00
|
|
|
end,
|
2022-04-27 15:42:28 +00:00
|
|
|
config = function()
|
|
|
|
require "plugins.configs.lspconfig"
|
|
|
|
end,
|
2022-01-30 07:21:46 +00:00
|
|
|
},
|
2021-08-22 07:49:15 +00:00
|
|
|
|
2022-04-27 15:42:28 +00:00
|
|
|
["ray-x/lsp_signature.nvim"] = {
|
2021-08-22 07:49:15 +00:00
|
|
|
after = "nvim-lspconfig",
|
2022-04-27 15:42:28 +00:00
|
|
|
config = function()
|
|
|
|
require("plugins.configs.others").signature()
|
|
|
|
end,
|
2022-01-30 07:21:46 +00:00
|
|
|
},
|
2021-06-24 17:19:42 +00:00
|
|
|
|
2022-04-27 15:42:28 +00:00
|
|
|
["andymass/vim-matchup"] = {
|
2021-08-26 09:40:26 +00:00
|
|
|
opt = true,
|
|
|
|
setup = function()
|
|
|
|
require("core.utils").packer_lazy_load "vim-matchup"
|
|
|
|
end,
|
2022-01-30 07:21:46 +00:00
|
|
|
},
|
2021-08-26 09:40:26 +00:00
|
|
|
|
2022-04-27 15:42:28 +00:00
|
|
|
["max397574/better-escape.nvim"] = {
|
2022-02-12 02:01:23 +00:00
|
|
|
event = "InsertCharPre",
|
2022-04-27 15:42:28 +00:00
|
|
|
config = function()
|
|
|
|
require("plugins.configs.others").better_escape()
|
|
|
|
end,
|
2022-01-30 07:21:46 +00:00
|
|
|
},
|
2021-08-07 05:55:23 +00:00
|
|
|
|
2021-08-27 01:14:58 +00:00
|
|
|
-- load luasnips + cmp related in insert mode only
|
|
|
|
|
2022-04-27 15:42:28 +00:00
|
|
|
["rafamadriz/friendly-snippets"] = {
|
2022-01-29 14:33:59 +00:00
|
|
|
module = "cmp_nvim_lsp",
|
2022-03-01 07:13:34 +00:00
|
|
|
event = "InsertEnter",
|
2022-01-30 07:21:46 +00:00
|
|
|
},
|
2022-01-29 14:33:59 +00:00
|
|
|
|
2022-04-27 15:42:28 +00:00
|
|
|
["hrsh7th/nvim-cmp"] = {
|
2022-02-12 02:01:23 +00:00
|
|
|
after = "friendly-snippets",
|
2022-04-27 15:42:28 +00:00
|
|
|
config = function()
|
|
|
|
require "plugins.configs.cmp"
|
|
|
|
end,
|
2022-01-30 07:21:46 +00:00
|
|
|
},
|
2021-08-27 01:14:58 +00:00
|
|
|
|
2022-04-27 15:42:28 +00:00
|
|
|
["L3MON4D3/LuaSnip"] = {
|
2021-08-27 02:41:46 +00:00
|
|
|
wants = "friendly-snippets",
|
2022-01-29 14:33:59 +00:00
|
|
|
after = "nvim-cmp",
|
2022-04-27 15:42:28 +00:00
|
|
|
config = function()
|
|
|
|
require("plugins.configs.others").luasnip()
|
|
|
|
end,
|
2022-01-30 07:21:46 +00:00
|
|
|
},
|
2021-08-27 01:14:58 +00:00
|
|
|
|
2022-04-27 15:42:28 +00:00
|
|
|
["saadparwaiz1/cmp_luasnip"] = {
|
|
|
|
after = "LuaSnip",
|
2022-01-30 07:21:46 +00:00
|
|
|
},
|
2021-08-27 01:14:58 +00:00
|
|
|
|
2022-04-27 15:42:28 +00:00
|
|
|
["hrsh7th/cmp-nvim-lua"] = {
|
2022-02-12 02:01:23 +00:00
|
|
|
after = "cmp_luasnip",
|
2022-01-30 07:21:46 +00:00
|
|
|
},
|
2021-08-27 01:14:58 +00:00
|
|
|
|
2022-04-27 15:42:28 +00:00
|
|
|
["hrsh7th/cmp-nvim-lsp"] = {
|
2022-01-29 14:33:59 +00:00
|
|
|
after = "cmp-nvim-lua",
|
2022-01-30 07:21:46 +00:00
|
|
|
},
|
2021-08-27 01:14:58 +00:00
|
|
|
|
2022-04-27 15:42:28 +00:00
|
|
|
["hrsh7th/cmp-buffer"] = {
|
2022-01-26 14:47:44 +00:00
|
|
|
after = "cmp-nvim-lsp",
|
2022-01-30 07:21:46 +00:00
|
|
|
},
|
2021-08-27 01:14:58 +00:00
|
|
|
|
2022-04-27 15:42:28 +00:00
|
|
|
["hrsh7th/cmp-path"] = {
|
2022-01-29 14:33:59 +00:00
|
|
|
after = "cmp-buffer",
|
2022-01-30 07:21:46 +00:00
|
|
|
},
|
|
|
|
|
2021-08-16 07:49:09 +00:00
|
|
|
-- misc plugins
|
2022-04-27 15:42:28 +00:00
|
|
|
["windwp/nvim-autopairs"] = {
|
|
|
|
after = "nvim-cmp",
|
|
|
|
config = function()
|
|
|
|
require("plugins.configs.others").autopairs()
|
|
|
|
end,
|
2022-01-30 07:21:46 +00:00
|
|
|
},
|
2021-05-12 17:23:35 +00:00
|
|
|
|
2022-04-27 15:42:28 +00:00
|
|
|
["goolord/alpha-nvim"] = {
|
|
|
|
disable = true,
|
|
|
|
config = function()
|
|
|
|
require "plugins.configs.alpha"
|
|
|
|
end,
|
2022-01-30 07:21:46 +00:00
|
|
|
},
|
2021-06-26 02:10:23 +00:00
|
|
|
|
2022-04-27 15:42:28 +00:00
|
|
|
["numToStr/Comment.nvim"] = {
|
2021-12-11 16:53:09 +00:00
|
|
|
module = "Comment",
|
2022-02-07 14:47:14 +00:00
|
|
|
keys = { "gcc" },
|
2022-04-27 15:42:28 +00:00
|
|
|
|
2021-08-22 07:49:15 +00:00
|
|
|
setup = function()
|
|
|
|
require("core.mappings").comment()
|
2021-08-16 07:49:09 +00:00
|
|
|
end,
|
2022-04-27 15:42:28 +00:00
|
|
|
|
|
|
|
config = function()
|
|
|
|
require("plugins.configs.others").comment()
|
|
|
|
end,
|
2022-01-30 07:21:46 +00:00
|
|
|
},
|
2021-06-24 17:21:39 +00:00
|
|
|
|
2021-08-22 07:49:15 +00:00
|
|
|
-- file managing , picker etc
|
2022-04-27 15:42:28 +00:00
|
|
|
["kyazdani42/nvim-tree.lua"] = {
|
|
|
|
cmd = { "NvimTreeToggle", "NvimTreeFocus" },
|
|
|
|
|
2021-08-22 07:49:15 +00:00
|
|
|
setup = function()
|
|
|
|
require("core.mappings").nvimtree()
|
2021-08-16 07:49:09 +00:00
|
|
|
end,
|
2022-04-27 15:42:28 +00:00
|
|
|
|
|
|
|
config = function()
|
|
|
|
require "plugins.configs.nvimtree"
|
|
|
|
end,
|
2022-01-30 07:21:46 +00:00
|
|
|
},
|
2021-06-26 02:22:48 +00:00
|
|
|
|
2022-04-27 15:42:28 +00:00
|
|
|
["nvim-telescope/telescope.nvim"] = {
|
2022-01-20 06:07:32 +00:00
|
|
|
module = "telescope",
|
2021-08-22 07:45:25 +00:00
|
|
|
cmd = "Telescope",
|
2022-04-27 15:42:28 +00:00
|
|
|
|
2021-08-22 07:45:25 +00:00
|
|
|
setup = function()
|
|
|
|
require("core.mappings").telescope()
|
|
|
|
end,
|
2022-04-27 15:42:28 +00:00
|
|
|
|
|
|
|
config = function()
|
|
|
|
require "plugins.configs.telescope"
|
|
|
|
end,
|
2022-01-30 07:21:46 +00:00
|
|
|
},
|
|
|
|
}
|
2022-02-13 07:39:07 +00:00
|
|
|
|
2022-04-29 05:04:44 +00:00
|
|
|
plugins = require("core.utils").remove_default_plugins(plugins)
|
2022-04-27 15:42:28 +00:00
|
|
|
-- merge user plugin table & default plugin table
|
|
|
|
plugins = require("core.utils").plugin_list(plugins)
|
2022-01-31 08:43:51 +00:00
|
|
|
|
2022-02-13 07:39:07 +00:00
|
|
|
return packer.startup(function(use)
|
2022-02-14 20:32:23 +00:00
|
|
|
for _, v in pairs(plugins) do
|
2022-02-13 07:39:07 +00:00
|
|
|
use(v)
|
2022-01-30 17:04:39 +00:00
|
|
|
end
|
2022-02-13 07:39:07 +00:00
|
|
|
end)
|