nvim: put plugins into opt/

this way supposedly we can explicitly load the plugin next to the
relevant configuration
This commit is contained in:
dogeystamp 2024-06-07 16:00:02 -04:00
parent e8308206bf
commit 6e4b1ecb82
Signed by: dogeystamp
GPG Key ID: 7225FE3592EFFA38
25 changed files with 50 additions and 25 deletions

36
.gitmodules vendored
View File

@ -17,52 +17,52 @@
# prompts
# telescope.vim
[submodule "src/.local/share/nvim/site/pack/3pp/start/telescope.nvim"]
path = src/.local/share/nvim/site/pack/3pp/start/telescope.nvim
path = src/.local/share/nvim/site/pack/3pp/opt/telescope.nvim
url = https://github.com/nvim-telescope/telescope.nvim.git
[submodule "src/.local/share/nvim/site/pack/3pp/start/plenary.nvim"]
path = src/.local/share/nvim/site/pack/3pp/start/plenary.nvim
path = src/.local/share/nvim/site/pack/3pp/opt/plenary.nvim
url = https://github.com/nvim-lua/plenary.nvim.git
# git symbols in the gutter
[submodule "src/.local/share/nvim/site/pack/3pp/start/vim-gitgutter"]
path = src/.local/share/nvim/site/pack/3pp/start/vim-gitgutter
path = src/.local/share/nvim/site/pack/3pp/opt/vim-gitgutter
url = https://github.com/airblade/vim-gitgutter.git
# auto close brackets and quotes
# coding.vim
[submodule "src/.local/share/nvim/site/pack/3pp/start/auto-pairs"]
path = src/.local/share/nvim/site/pack/3pp/start/auto-pairs
path = src/.local/share/nvim/site/pack/3pp/opt/auto-pairs
url = https://github.com/jiangmiao/auto-pairs
# language smarts
# coding.lua
[submodule "src/.local/share/nvim/site/pack/3pp/start/nvim-lspconfig"]
path = src/.local/share/nvim/site/pack/3pp/start/nvim-lspconfig
path = src/.local/share/nvim/site/pack/3pp/opt/nvim-lspconfig
url = https://github.com/neovim/nvim-lspconfig.git
[submodule "src/.local/share/nvim/site/pack/3pp/start/nvim-cmp"]
path = src/.local/share/nvim/site/pack/3pp/start/nvim-cmp
path = src/.local/share/nvim/site/pack/3pp/opt/nvim-cmp
url = https://github.com/hrsh7th/nvim-cmp.git
[submodule "src/.local/share/nvim/site/pack/3pp/start/cmp-nvim-lsp"]
path = src/.local/share/nvim/site/pack/3pp/start/cmp-nvim-lsp
path = src/.local/share/nvim/site/pack/3pp/opt/cmp-nvim-lsp
url = https://github.com/hrsh7th/cmp-nvim-lsp.git
[submodule "src/.local/share/nvim/site/pack/3pp/start/nvim-treesitter"]
path = src/.local/share/nvim/site/pack/3pp/start/nvim-treesitter
path = src/.local/share/nvim/site/pack/3pp/opt/nvim-treesitter
url = https://github.com/nvim-treesitter/nvim-treesitter.git
# intelligent motions based on treesitter
[submodule "src/.local/share/nvim/site/pack/3pp/start/nvim-treesitter-textobjects"]
path = src/.local/share/nvim/site/pack/3pp/start/nvim-treesitter-textobjects
path = src/.local/share/nvim/site/pack/3pp/opt/nvim-treesitter-textobjects
url = https://github.com/nvim-treesitter/nvim-treesitter-textobjects
# error/warning/info box
# coding.lua
[submodule "src/.local/share/nvim/site/pack/3pp/start/trouble.nvim"]
path = src/.local/share/nvim/site/pack/3pp/start/trouble.nvim
path = src/.local/share/nvim/site/pack/3pp/opt/trouble.nvim
url = https://github.com/folke/trouble.nvim
# aesthetic changes
# init.lua
[submodule "src/.local/share/nvim/site/pack/3pp/start/dressing.nvim"]
path = src/.local/share/nvim/site/pack/3pp/start/dressing.nvim
path = src/.local/share/nvim/site/pack/3pp/opt/dressing.nvim
url = https://github.com/stevearc/dressing.nvim.git
# plain-text-accounting ledger ftplugin
@ -80,30 +80,30 @@
# color theme
# init.lua
[submodule "src/.local/share/nvim/site/pack/3pp/start/nvim-noirbuddy"]
path = src/.local/share/nvim/site/pack/3pp/start/nvim-noirbuddy
path = src/.local/share/nvim/site/pack/3pp/opt/nvim-noirbuddy
url = https://github.com/jesseleite/nvim-noirbuddy.git
[submodule "src/.local/share/nvim/site/pack/3pp/start/colorbuddy.nvim"]
path = src/.local/share/nvim/site/pack/3pp/start/colorbuddy.nvim
path = src/.local/share/nvim/site/pack/3pp/opt/colorbuddy.nvim
url = https://github.com/tjdevries/colorbuddy.nvim.git
# debug adapter protocol
# debugging.lua
[submodule "src/.local/share/nvim/site/pack/3pp/start/nvim-dap"]
path = src/.local/share/nvim/site/pack/3pp/start/nvim-dap
path = src/.local/share/nvim/site/pack/3pp/opt/nvim-dap
url = https://github.com/mfussenegger/nvim-dap.git
[submodule "src/.local/share/nvim/site/pack/3pp/start/nvim-dap-ui"]
path = src/.local/share/nvim/site/pack/3pp/start/nvim-dap-ui
path = src/.local/share/nvim/site/pack/3pp/opt/nvim-dap-ui
url = https://github.com/rcarriga/nvim-dap-ui.git
[submodule "src/.local/share/nvim/site/pack/3pp/start/nvim-nio"]
path = src/.local/share/nvim/site/pack/3pp/start/nvim-nio
path = src/.local/share/nvim/site/pack/3pp/opt/nvim-nio
url = https://github.com/nvim-neotest/nvim-nio
# snippet support
# snippets.lua
# (also coding.lua becuase nvim-cmp uses this too)
[submodule "src/.local/share/nvim/site/pack/3pp/start/LuaSnip"]
path = src/.local/share/nvim/site/pack/3pp/start/LuaSnip
path = src/.local/share/nvim/site/pack/3pp/opt/LuaSnip
url = https://github.com/L3MON4D3/LuaSnip
[submodule "src/.local/share/nvim/site/pack/3pp/start/cmp_luasnip"]
path = src/.local/share/nvim/site/pack/3pp/start/cmp_luasnip
path = src/.local/share/nvim/site/pack/3pp/opt/cmp_luasnip
url = https://github.com/saadparwaiz1/cmp_luasnip

View File

@ -84,4 +84,5 @@ set foldexpr=nvim_treesitter#foldexpr()
set foldlevel=99
" auto-pairs
packadd auto-pairs
let g:AutoPairsFlyMode = 0

View File

@ -27,11 +27,18 @@ vim.api.nvim_create_autocmd(
}
)
------
-- git gutter
------
vim.cmd.packadd("vim-gitgutter")
------
-- syntax highlighting
-- plug: nvim-treesitter
------
vim.cmd.packadd("nvim-treesitter")
require 'nvim-treesitter.configs'.setup {
ensure_installed = { "c", "cpp", "javascript", "typescript", "python", "vim", "fish", "bash", "lua", "rust" },
sync_install = false,
@ -51,8 +58,8 @@ require 'nvim-treesitter.configs'.setup {
------
-- treesitter (language intelligent) motions
-- plug: nvim-treesitter-textobjects
------
vim.cmd.packadd("nvim-treesitter-textobjects")
require("nvim-treesitter.configs").setup {
textobjects = {
select = {
@ -71,8 +78,8 @@ require("nvim-treesitter.configs").setup {
------
-- diagnostics box
-- plug: trouble.nvim
------
vim.cmd.packadd("trouble.nvim")
require('trouble').setup({
icons = false,
fold_open = "v", -- icon used for open folds
@ -104,8 +111,8 @@ keymap("gR", "<cmd>TroubleToggle lsp_references<cr>")
------
-- language server (LSP)
-- plug: nvim-lspconfig
------
vim.cmd.packadd("nvim-lspconfig")
local on_attach = function(client, bufnr)
local function buf_set_option(...) vim.api.nvim_buf_set_option(bufnr, ...) end
-- Enable completion triggered by <c-x><c-o>
@ -193,8 +200,10 @@ end
------
-- completions
-- plug: nvim-cmp, cmp-nvim-lsp
------
vim.cmd.packadd("nvim-cmp")
vim.cmd.packadd("cmp-nvim-lsp")
local cmp = require('cmp')
cmp.setup({
window = {

View File

@ -3,6 +3,12 @@
local confutil = require("confutil")
local keymap = confutil.keymap
-- dependency
vim.cmd.packadd("nvim-nio")
vim.cmd.packadd("nvim-dap")
vim.cmd.packadd("nvim-dap-ui")
local dap = require("dap")
local dapui = require("dapui")

View File

@ -1,5 +1,7 @@
-- lua entry point
vim.cmd.packadd("plenary.nvim")
local confutil = require("confutil")
local keymap = confutil.keymap
@ -16,13 +18,16 @@ keymap("<leader>uu", ":let @+ = expand('<cfile>')<cr>")
------
-- fancy prompts
-- plug: dressing.nvim, telescope.nvim, plenary.nvim
------
vim.cmd.packadd("dressing.nvim")
require('dressing').setup({
input = {
insert_only = false,
}
})
-- requires plenary.nvim
vim.cmd.packadd("telescope.nvim")
keymap("<leader>ef", "<cmd>Telescope find_files<cr>")
keymap("<leader>eg", "<cmd>Telescope live_grep<cr>")
keymap("<leader>em", "<cmd>Telescope buffers<cr>")

View File

@ -1,5 +1,7 @@
-- Snippet engine
vim.cmd.packadd("LuaSnip")
-- see coding.lua because it also uses luasnip
-- snippets live in .config/nvim/snippets/

View File

@ -1,8 +1,10 @@
------
-- color theme
-- plug: nvim-noirbuddy, colorbuddy.nvim
------
vim.cmd.packadd("nvim-noirbuddy")
vim.cmd.packadd("colorbuddy.nvim")
require("noirbuddy").setup({
colors = {
primary = "#99AABB"