From 1b5730d51195fee74f3544bd29d017c46da3dea3 Mon Sep 17 00:00:00 2001 From: kylo252 <59826753+kylo252@users.noreply.github.com> Date: Wed, 11 Aug 2021 17:29:20 +0200 Subject: feat: make autopairs configurable --- lua/plugins.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'lua/plugins.lua') diff --git a/lua/plugins.lua b/lua/plugins.lua index 8e497075..c2a0e0e2 100644 --- a/lua/plugins.lua +++ b/lua/plugins.lua @@ -68,7 +68,7 @@ return { -- event = "InsertEnter", after = "nvim-compe", config = function() - require "core.autopairs" + require("core.autopairs").setup() if lvim.builtin.autopairs.on_config_done then lvim.builtin.autopairs.on_config_done(require "nvim-autopairs") end -- cgit v1.2.3 From d512b57918ead21dec97bf33a7c63e9ea38310c4 Mon Sep 17 00:00:00 2001 From: kylo252 <59826753+kylo252@users.noreply.github.com> Date: Wed, 11 Aug 2021 17:34:16 +0200 Subject: allow disabling autopairs completely --- lua/plugins.lua | 1 + 1 file changed, 1 insertion(+) (limited to 'lua/plugins.lua') diff --git a/lua/plugins.lua b/lua/plugins.lua index c2a0e0e2..cacc1e9f 100644 --- a/lua/plugins.lua +++ b/lua/plugins.lua @@ -73,6 +73,7 @@ return { lvim.builtin.autopairs.on_config_done(require "nvim-autopairs") end end, + disable = not lvim.builtin.autopairs.active, }, -- Treesitter -- cgit v1.2.3 From 4fd72b1be2c1220a519d5b8d58219939a11df0c9 Mon Sep 17 00:00:00 2001 From: abzcoding Date: Thu, 12 Aug 2021 12:05:54 +0430 Subject: Revert "Merge pull request #1294 from kylo252/autopairs-refactor" This reverts commit d71c3280c88c72665a21875522f0be3b157075b4, reversing changes made to a3344203818658441d176fe279e1978505940432. --- lua/plugins.lua | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'lua/plugins.lua') diff --git a/lua/plugins.lua b/lua/plugins.lua index cacc1e9f..8e497075 100644 --- a/lua/plugins.lua +++ b/lua/plugins.lua @@ -68,12 +68,11 @@ return { -- event = "InsertEnter", after = "nvim-compe", config = function() - require("core.autopairs").setup() + require "core.autopairs" if lvim.builtin.autopairs.on_config_done then lvim.builtin.autopairs.on_config_done(require "nvim-autopairs") end end, - disable = not lvim.builtin.autopairs.active, }, -- Treesitter -- cgit v1.2.3 From 6eb75c5678ddb4d040f644e331e222078b99b3a1 Mon Sep 17 00:00:00 2001 From: kylo252 <59826753+kylo252@users.noreply.github.com> Date: Sun, 15 Aug 2021 17:38:47 +0200 Subject: [Refactor] Clean-up redundant module-load checks (#1011) --- lua/plugins.lua | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) (limited to 'lua/plugins.lua') diff --git a/lua/plugins.lua b/lua/plugins.lua index 8e497075..5353de5b 100644 --- a/lua/plugins.lua +++ b/lua/plugins.lua @@ -131,15 +131,9 @@ return { "terrortylor/nvim-comment", event = "BufRead", config = function() - local status_ok, nvim_comment = pcall(require, "nvim_comment") - if not status_ok then - local Log = require "core.log" - Log:get_default().error "Failed to load nvim-comment" - return - end - nvim_comment.setup() + require("nvim_comment").setup() if lvim.builtin.comment.on_config_done then - lvim.builtin.comment.on_config_done(nvim_comment) + lvim.builtin.comment.on_config_done(require "nvim_comment") end end, }, -- cgit v1.2.3 From 335e707b2aae38c0cd5d0d962b27038ab1117aa6 Mon Sep 17 00:00:00 2001 From: kylo252 <59826753+kylo252@users.noreply.github.com> Date: Tue, 17 Aug 2021 17:20:18 +0200 Subject: [Feature] Make the rest of the builtins configurable (#1318) --- lua/plugins.lua | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) (limited to 'lua/plugins.lua') diff --git a/lua/plugins.lua b/lua/plugins.lua index 5353de5b..c9e7f3c2 100644 --- a/lua/plugins.lua +++ b/lua/plugins.lua @@ -27,6 +27,7 @@ return { lvim.builtin.telescope.on_config_done(require "telescope") end end, + disable = not lvim.builtin.telescope.active, }, -- Completion & Snippets @@ -39,6 +40,7 @@ return { lvim.builtin.compe.on_config_done(require "compe") end end, + disable = not lvim.builtin.compe.active, -- wants = "vim-vsnip", -- requires = { -- { @@ -56,10 +58,12 @@ return { "hrsh7th/vim-vsnip", -- wants = "friendly-snippets", event = "InsertEnter", + disable = not lvim.builtin.compe.active, }, { "rafamadriz/friendly-snippets", event = "InsertCharPre", + disable = not lvim.builtin.compe.active, }, -- Autopairs @@ -68,11 +72,12 @@ return { -- event = "InsertEnter", after = "nvim-compe", config = function() - require "core.autopairs" + require("core.autopairs").setup() if lvim.builtin.autopairs.on_config_done then lvim.builtin.autopairs.on_config_done(require "nvim-autopairs") end end, + disable = not lvim.builtin.autopairs.active or not lvim.builtin.compe.active, }, -- Treesitter @@ -100,6 +105,7 @@ return { lvim.builtin.nvimtree.on_config_done(require "nvim-tree.config") end end, + disable = not lvim.builtin.nvimtree.active, }, { @@ -112,6 +118,7 @@ return { end end, event = "BufRead", + disable = not lvim.builtin.gitsigns.active, }, -- Whichkey @@ -124,6 +131,7 @@ return { end end, event = "BufWinEnter", + disable = not lvim.builtin.which_key.active, }, -- Comments @@ -136,6 +144,7 @@ return { lvim.builtin.comment.on_config_done(require "nvim_comment") end end, + disable = not lvim.builtin.comment.active, }, -- vim-rooter -- cgit v1.2.3 From b9b9c69615b469146e3cc75adcf9bd61047404eb Mon Sep 17 00:00:00 2001 From: Ahmed Khalf Date: Wed, 18 Aug 2021 09:34:26 +0400 Subject: [Refactor]: Remove vim-rooter and smart-cwd; then use project.nvim (#1315) * Replace vim-rooter with project.nvim * Implement stylua format * Remove smart_cwd * Implicitly update nvim-tree dir when project active * Link datapath to cache * Fix stylua * Fix lint * Fix telescope bug * Fix telescope dependency * Fix telescope once and for all * Fix telescope once again --- lua/plugins.lua | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) (limited to 'lua/plugins.lua') diff --git a/lua/plugins.lua b/lua/plugins.lua index c9e7f3c2..1cf494bc 100644 --- a/lua/plugins.lua +++ b/lua/plugins.lua @@ -147,17 +147,16 @@ return { disable = not lvim.builtin.comment.active, }, - -- vim-rooter + -- project.nvim { - "airblade/vim-rooter", - -- event = "BufReadPre", + "ahmedkhalf/project.nvim", config = function() - require("core.rooter").setup() - if lvim.builtin.rooter.on_config_done then - lvim.builtin.rooter.on_config_done() + require("core.project").setup() + if lvim.builtin.project.on_config_done then + lvim.builtin.project.on_config_done() end end, - disable = not lvim.builtin.rooter.active, + disable = not lvim.builtin.project.active, }, -- Icons -- cgit v1.2.3 From 85fe093efb8353552171575809c02a5e9124fa68 Mon Sep 17 00:00:00 2001 From: chaeing Date: Fri, 20 Aug 2021 02:16:29 -0700 Subject: [Feature] switch galaxyline to lualine (#1329) --- lua/plugins.lua | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) (limited to 'lua/plugins.lua') diff --git a/lua/plugins.lua b/lua/plugins.lua index 1cf494bc..9aaea922 100644 --- a/lua/plugins.lua +++ b/lua/plugins.lua @@ -164,15 +164,13 @@ return { -- Status Line and Bufferline { - "glepnir/galaxyline.nvim", + -- "hoob3rt/lualine.nvim", + "shadmansaleh/lualine.nvim", + -- "Lunarvim/lualine.nvim", config = function() - require "core.galaxyline" - if lvim.builtin.galaxyline.on_config_done then - lvim.builtin.galaxyline.on_config_done(require "galaxyline") - end + require("core.lualine").setup() end, - event = "BufWinEnter", - disable = not lvim.builtin.galaxyline.active, + disable = not lvim.builtin.lualine.active, }, { -- cgit v1.2.3 From d85584d09f9028fa4202cea473f7f0ae3c531aef Mon Sep 17 00:00:00 2001 From: devtoi <508254+devtoi@users.noreply.github.com> Date: Sun, 22 Aug 2021 20:03:19 +0200 Subject: [Refactor/Bugfix] move on_config_done callbacks to relevant setup() (#1175) * Make autopairs config consistent with others * Fix two typos for autopairs * Remove extranous autopairs code. Return on setup * Remove extranous else for autopairs completion confirmation * Move on_config_done callbacks to setup functions. * Add on_config_done completion for builtins lacking a config function * enables galaxyline callbacks to work properly * Add modules for more builtins * Finish streamline of config function in plugin setup * Fix double use of which_key/wk * Fix erroneous remove of functionality in autopairs completion * consistency fixes * Work around telescope not found at config time * Match plugin definition of project and lualine with others * fix: restore config callback syntax Co-authored-by: Johan Melin Co-authored-by: rebuilt Co-authored-by: Luc Sinet Co-authored-by: kylo252 <59826753+kylo252@users.noreply.github.com> --- lua/plugins.lua | 44 +------------------------------------------- 1 file changed, 1 insertion(+), 43 deletions(-) (limited to 'lua/plugins.lua') diff --git a/lua/plugins.lua b/lua/plugins.lua index 9aaea922..5aaac3ce 100644 --- a/lua/plugins.lua +++ b/lua/plugins.lua @@ -8,11 +8,8 @@ return { "kabouzeid/nvim-lspinstall", event = "VimEnter", config = function() - local lspinstall = require "lspinstall" + local lspinstall = require "core.lspinstall" lspinstall.setup() - if lvim.builtin.lspinstall.on_config_done then - lvim.builtin.lspinstall.on_config_done(lspinstall) - end end, }, @@ -23,9 +20,6 @@ return { "nvim-telescope/telescope.nvim", config = function() require("core.telescope").setup() - if lvim.builtin.telescope.on_config_done then - lvim.builtin.telescope.on_config_done(require "telescope") - end end, disable = not lvim.builtin.telescope.active, }, @@ -36,9 +30,6 @@ return { event = "InsertEnter", config = function() require("core.compe").setup() - if lvim.builtin.compe.on_config_done then - lvim.builtin.compe.on_config_done(require "compe") - end end, disable = not lvim.builtin.compe.active, -- wants = "vim-vsnip", @@ -73,9 +64,6 @@ return { after = "nvim-compe", config = function() require("core.autopairs").setup() - if lvim.builtin.autopairs.on_config_done then - lvim.builtin.autopairs.on_config_done(require "nvim-autopairs") - end end, disable = not lvim.builtin.autopairs.active or not lvim.builtin.compe.active, }, @@ -87,9 +75,6 @@ return { -- run = ":TSUpdate", config = function() require("core.treesitter").setup() - if lvim.builtin.treesitter.on_config_done then - lvim.builtin.treesitter.on_config_done(require "nvim-treesitter.configs") - end end, }, @@ -101,9 +86,6 @@ return { -- commit = "fd7f60e242205ea9efc9649101c81a07d5f458bb", config = function() require("core.nvimtree").setup() - if lvim.builtin.nvimtree.on_config_done then - lvim.builtin.nvimtree.on_config_done(require "nvim-tree.config") - end end, disable = not lvim.builtin.nvimtree.active, }, @@ -113,9 +95,6 @@ return { config = function() require("core.gitsigns").setup() - if lvim.builtin.gitsigns.on_config_done then - lvim.builtin.gitsigns.on_config_done(require "gitsigns") - end end, event = "BufRead", disable = not lvim.builtin.gitsigns.active, @@ -126,9 +105,6 @@ return { "folke/which-key.nvim", config = function() require("core.which-key").setup() - if lvim.builtin.which_key.on_config_done then - lvim.builtin.which_key.on_config_done(require "which-key") - end end, event = "BufWinEnter", disable = not lvim.builtin.which_key.active, @@ -140,9 +116,6 @@ return { event = "BufRead", config = function() require("nvim_comment").setup() - if lvim.builtin.comment.on_config_done then - lvim.builtin.comment.on_config_done(require "nvim_comment") - end end, disable = not lvim.builtin.comment.active, }, @@ -152,9 +125,6 @@ return { "ahmedkhalf/project.nvim", config = function() require("core.project").setup() - if lvim.builtin.project.on_config_done then - lvim.builtin.project.on_config_done() - end end, disable = not lvim.builtin.project.active, }, @@ -177,9 +147,6 @@ return { "romgrk/barbar.nvim", config = function() require("core.bufferline").setup() - if lvim.builtin.bufferline.on_config_done then - lvim.builtin.bufferline.on_config_done() - end end, event = "BufWinEnter", disable = not lvim.builtin.bufferline.active, @@ -191,9 +158,6 @@ return { -- event = "BufWinEnter", config = function() require("core.dap").setup() - if lvim.builtin.dap.on_config_done then - lvim.builtin.dap.on_config_done(require "dap") - end end, disable = not lvim.builtin.dap.active, }, @@ -212,9 +176,6 @@ return { event = "BufWinEnter", config = function() require("core.dashboard").setup() - if lvim.builtin.dashboard.on_config_done then - lvim.builtin.dashboard.on_config_done(require "dashboard") - end end, disable = not lvim.builtin.dashboard.active, }, @@ -225,9 +186,6 @@ return { event = "BufWinEnter", config = function() require("core.terminal").setup() - if lvim.builtin.terminal.on_config_done then - lvim.builtin.terminal.on_config_done(require "toggleterm") - end end, disable = not lvim.builtin.terminal.active, }, -- cgit v1.2.3 From c7a5122fe2c14dba0f28f1c077f838f957884afc Mon Sep 17 00:00:00 2001 From: christianchiarulli Date: Sun, 29 Aug 2021 14:11:04 -0400 Subject: fix: Cursorhold Event not firing after entering lunarvim from dashboard->telescope closes #1413 --- lua/plugins.lua | 1 + 1 file changed, 1 insertion(+) (limited to 'lua/plugins.lua') diff --git a/lua/plugins.lua b/lua/plugins.lua index 5aaac3ce..8a0692f2 100644 --- a/lua/plugins.lua +++ b/lua/plugins.lua @@ -4,6 +4,7 @@ return { { "neovim/nvim-lspconfig" }, { "tamago324/nlsp-settings.nvim" }, { "jose-elias-alvarez/null-ls.nvim" }, + { "antoinemadec/FixCursorHold.nvim" }, -- Needed while issue https://github.com/neovim/neovim/issues/12587 is still open { "kabouzeid/nvim-lspinstall", event = "VimEnter", -- cgit v1.2.3