Add rest of settings
This commit is contained in:
@@ -0,0 +1,2 @@
|
||||
vim.treesitter.start()
|
||||
|
||||
@@ -0,0 +1,2 @@
|
||||
vim.treesitter.start()
|
||||
|
||||
@@ -0,0 +1 @@
|
||||
vim.treesitter.start()
|
||||
@@ -0,0 +1,2 @@
|
||||
vim.treesitter.start()
|
||||
|
||||
@@ -0,0 +1 @@
|
||||
vim.treesitter.start()
|
||||
@@ -30,20 +30,25 @@ if not vim.loop.fs_stat(lazypath) then
|
||||
end
|
||||
vim.opt.rtp:prepend(lazypath)
|
||||
|
||||
require("autocmds")
|
||||
require("lazy").setup({
|
||||
require("plugins.appearance"),
|
||||
require("plugins.editor"),
|
||||
require("plugins.git"),
|
||||
require("plugins.ai"),
|
||||
require("plugins.orgmode"),
|
||||
require("plugins.lsp"),
|
||||
require("plugins.treesitter"),
|
||||
require("plugins.dap"),
|
||||
require("plugins.haunt"),
|
||||
require("plugins.appearance"),
|
||||
})
|
||||
|
||||
-- LSP
|
||||
vim.diagnostic.config({ virtual_text = true })
|
||||
vim.lsp.inlay_hint.enable(true)
|
||||
|
||||
vim.cmd([[colorscheme tokyonight-night]])
|
||||
-- GUI
|
||||
vim.o.guifont = "JetBrainsMono Nerd Font:h12"
|
||||
|
||||
require("keymap")
|
||||
require("clipboard")
|
||||
|
||||
+41
-26
@@ -1,39 +1,54 @@
|
||||
{
|
||||
"Comment.nvim": { "branch": "master", "commit": "e30b7f2008e52442154b66f7c519bfd2f1e32acb" },
|
||||
"CopilotChat.nvim": { "branch": "main", "commit": "21bdecb25aa72119d11d7fc08c7e0ce323f1b540" },
|
||||
"bento.nvim": { "branch": "main", "commit": "d5a2edea7ea2a5353778d0996a881be699eb4402" },
|
||||
"blink.cmp": { "branch": "main", "commit": "b19413d214068f316c78978b08264ed1c41830ec" },
|
||||
"conform.nvim": { "branch": "master", "commit": "238f542a118984a88124fc915d5b981680418707" },
|
||||
"bento.nvim": { "branch": "main", "commit": "aee8a542bc1839ff1764992ef2aa41c981d0bba4" },
|
||||
"blink.cmp": { "branch": "main", "commit": "78336bc89ee5365633bcf754d93df01678b5c08f" },
|
||||
"codecompanion.nvim": { "branch": "main", "commit": "f70759ee8b63b46ea0cf158dc22daa2a5e9c6319" },
|
||||
"codediff.nvim": { "branch": "main", "commit": "8afc229d38dc13ce71b2ffbb860084b2c726e061" },
|
||||
"conform.nvim": { "branch": "master", "commit": "dca1a190aa85f9065979ef35802fb77131911106" },
|
||||
"copilot-lsp": { "branch": "main", "commit": "1b6d8273594643f51bb4c0c1d819bdb21b42159d" },
|
||||
"copilot.lua": { "branch": "master", "commit": "5ace9ecd0db9a7a6c14064e4ce4ede5b800325f3" },
|
||||
"copilot.lua": { "branch": "master", "commit": "78c638293f0ea6a2245eca46e9933ee271792d7e" },
|
||||
"diffview.nvim": { "branch": "main", "commit": "4516612fe98ff56ae0415a259ff6361a89419b0a" },
|
||||
"fidget.nvim": { "branch": "main", "commit": "64463022a1f2ff1318ab22a2ea4125ed9313a483" },
|
||||
"fidget.nvim": { "branch": "main", "commit": "889e2e96edef4e144965571d46f7a77bcc4d0ddf" },
|
||||
"flash.nvim": { "branch": "main", "commit": "fcea7ff883235d9024dc41e638f164a450c14ca2" },
|
||||
"friendly-snippets": { "branch": "main", "commit": "572f5660cf05f8cd8834e096d7b4c921ba18e175" },
|
||||
"fzf": { "branch": "master", "commit": "d1f037059ab57aa1c70abe124b2b72a710f4a28f" },
|
||||
"fzf-lua": { "branch": "main", "commit": "e7773d0c863a31bfc8ab72dd1adbec4611a35409" },
|
||||
"fzf.vim": { "branch": "master", "commit": "ddc14a6a5471147e2a38e6b32a7268282f669b0a" },
|
||||
"indent-blankline.nvim": { "branch": "master", "commit": "005b56001b2cb30bfa61b7986bc50657816ba4ba" },
|
||||
"friendly-snippets": { "branch": "main", "commit": "6cd7280adead7f586db6fccbd15d2cac7e2188b9" },
|
||||
"fzf": { "branch": "master", "commit": "6fefe025461b168eac2546ccba3403b70eb5da16" },
|
||||
"fzf-lua": { "branch": "main", "commit": "b437bafc981a180d609bb4092c56ce8999f7a2c4" },
|
||||
"fzf.vim": { "branch": "master", "commit": "b9624aa012ddcbae9e79964bfd30cc1fbe3cf263" },
|
||||
"git-conflict.nvim": { "branch": "main", "commit": "4bbfdd92d547d2862a75b4e80afaf30e73f7bbb4" },
|
||||
"gitsigns.nvim": { "branch": "main", "commit": "6d808f99bd63303646794406e270bd553ad7792e" },
|
||||
"glance.nvim": { "branch": "master", "commit": "bf86d8b79dce808e65fdb6e9269d0b4ed6d2eefc" },
|
||||
"go.nvim": { "branch": "master", "commit": "ed77921e3f0bdf9e52cf9fab2e0f4c69ef2a7e04" },
|
||||
"guihua.lua": { "branch": "master", "commit": "7c364432c2f9153ed068f4eab1989edd9f3fd302" },
|
||||
"haunt.nvim": { "branch": "main", "commit": "666d83868bac8b38f1dc765d9da6eca4d92c826f" },
|
||||
"indent-blankline.nvim": { "branch": "master", "commit": "d28a3f70721c79e3c5f6693057ae929f3d9c0a03" },
|
||||
"lazy.nvim": { "branch": "main", "commit": "306a05526ada86a7b30af95c5cc81ffba93fef97" },
|
||||
"lazydev.nvim": { "branch": "main", "commit": "5231c62aa83c2f8dc8e7ba957aa77098cda1257d" },
|
||||
"live-preview.nvim": { "branch": "main", "commit": "4b4cd2262f7fed487f112e18ddba46dabf0cb7d2" },
|
||||
"lualine.nvim": { "branch": "master", "commit": "47f91c416daef12db467145e16bed5bbfe00add8" },
|
||||
"neogit": { "branch": "master", "commit": "d8bf9102692250193b855acd9025a826f1af2729" },
|
||||
"nvim-autopairs": { "branch": "master", "commit": "c2a0dd0d931d0fb07665e1fedb1ea688da3b80b4" },
|
||||
"nvim-lspconfig": { "branch": "master", "commit": "92ee7d42320edfbb81f3cad851314ab197fa324a" },
|
||||
"nvim-treesitter": { "branch": "main", "commit": "5a7e5638e7d220575b1c22c8a2e099b52231886e" },
|
||||
"nvim-treesitter-textobjects": { "branch": "main", "commit": "d0d12338230c1ce4ce27373f5b8d50a8c691794b" },
|
||||
"lazydev.nvim": { "branch": "main", "commit": "ff2cbcba459b637ec3fd165a2be59b7bbaeedf0d" },
|
||||
"live-preview.nvim": { "branch": "main", "commit": "c1fcf75c5f9c9c01dd392852de44204b60f1b5b1" },
|
||||
"lualine.nvim": { "branch": "master", "commit": "131a558e13f9f28b15cd235557150ccb23f89286" },
|
||||
"mason.nvim": { "branch": "main", "commit": "cb8445f8ce85d957416c106b780efd51c6298f89" },
|
||||
"neogit": { "branch": "master", "commit": "88000e7e60177558d1b428a0d561c92e5d81341e" },
|
||||
"nui.nvim": { "branch": "main", "commit": "de740991c12411b663994b2860f1a4fd0937c130" },
|
||||
"nvim-autopairs": { "branch": "master", "commit": "59bce2eef357189c3305e25bc6dd2d138c1683f5" },
|
||||
"nvim-dap": { "branch": "master", "commit": "45a69eba683a2c448dd9ecfc4de89511f0646b5f" },
|
||||
"nvim-dap-ui": { "branch": "master", "commit": "1a66cabaa4a4da0be107d5eda6d57242f0fe7e49" },
|
||||
"nvim-jdtls": { "branch": "master", "commit": "77ccaeb422f8c81b647605da5ddb4a7f725cda90" },
|
||||
"nvim-lspconfig": { "branch": "master", "commit": "0e25d7445ba0d7cc0ad02a39aa843cc8b9d2525e" },
|
||||
"nvim-treesitter": { "branch": "main", "commit": "4916d6592ede8c07973490d9322f187e07dfefac" },
|
||||
"nvim-treesitter-textobjects": { "branch": "main", "commit": "851e865342e5a4cb1ae23d31caf6e991e1c99f1e" },
|
||||
"nvim-ufo": { "branch": "main", "commit": "ab3eb124062422d276fae49e0dd63b3ad1062cfc" },
|
||||
"nvim-web-devicons": { "branch": "master", "commit": "803353450c374192393f5387b6a0176d0972b848" },
|
||||
"oil.nvim": { "branch": "master", "commit": "d278dc40f9de9980868a0a55fa666fba5e6aeacb" },
|
||||
"nvim-web-devicons": { "branch": "master", "commit": "4fc505ac7bd7692824a142e96e5f529c133862f8" },
|
||||
"oil.nvim": { "branch": "master", "commit": "0fcc83805ad11cf714a949c98c605ed717e0b83e" },
|
||||
"org-roam.nvim": { "branch": "main", "commit": "34d1d113cd139ea903125305310be3d7c1067484" },
|
||||
"orgmode": { "branch": "master", "commit": "4da28a06d7a8b2563f1308c4550604f36e3c299f" },
|
||||
"plenary.nvim": { "branch": "master", "commit": "b9fd5226c2f76c951fc8ed5923d85e4de065e509" },
|
||||
"plenary.nvim": { "branch": "master", "commit": "74b06c6c75e4eeb3108ec01852001636d85a932b" },
|
||||
"promise-async": { "branch": "main", "commit": "119e8961014c9bfaf1487bf3c2a393d254f337e2" },
|
||||
"rainbow-delimiters.nvim": { "branch": "master", "commit": "d6b802552cbe7d643a3b6b31f419c248d1f1e220" },
|
||||
"snacks.nvim": { "branch": "main", "commit": "fe7cfe9800a182274d0f868a74b7263b8c0c020b" },
|
||||
"tokyonight.nvim": { "branch": "main", "commit": "5da1b76e64daf4c5d410f06bcb6b9cb640da7dfd" },
|
||||
"treesj": { "branch": "main", "commit": "186084dee5e9c8eec40f6e39481c723dd567cb05" },
|
||||
"rainbow-delimiters.nvim": { "branch": "master", "commit": "08783ec022e7ddefe0f12a16f1ac4968f55478b0" },
|
||||
"scrollEOF.nvim": { "branch": "master", "commit": "e462b9a07b8166c3e8011f1dcbc6bf68b67cd8d7" },
|
||||
"snacks.nvim": { "branch": "main", "commit": "ad9ede6a9cddf16cedbd31b8932d6dcdee9b716e" },
|
||||
"todo-comments.nvim": { "branch": "main", "commit": "31e3c38ce9b29781e4422fc0322eb0a21f4e8668" },
|
||||
"tokyonight.nvim": { "branch": "main", "commit": "cdc07ac78467a233fd62c493de29a17e0cf2b2b6" },
|
||||
"treesj": { "branch": "main", "commit": "5fa4e7ba3517f8fe743bb4488f9e9c7ce83330fc" },
|
||||
"vim-lastplace": { "branch": "master", "commit": "e58cb0df716d3c88605ae49db5c4741db8b48aa9" },
|
||||
"vscode_modern_theme.nvim": { "branch": "main", "commit": "22371eeb704bed395262e552248c998ef7f41254" },
|
||||
"which-key.nvim": { "branch": "main", "commit": "3aab2147e74890957785941f0c1ad87d0a44c15a" }
|
||||
}
|
||||
|
||||
@@ -0,0 +1,18 @@
|
||||
-- Set the colorscheme for the Copilot suggestions and annotations
|
||||
vim.api.nvim_create_autocmd("ColorScheme", {
|
||||
callback = function()
|
||||
vim.api.nvim_set_hl(0, "CopilotSuggestion", { fg = "#f3f412", italic = true })
|
||||
vim.api.nvim_set_hl(0, "CopilotAnnotation", { fg = "#f3f412" })
|
||||
end,
|
||||
})
|
||||
|
||||
-- Enable inlay hints
|
||||
vim.api.nvim_create_autocmd("LspAttach", {
|
||||
callback = function(args)
|
||||
local client = vim.lsp.get_client_by_id(args.data.client_id)
|
||||
if client.server_capabilities.inlayHintProvider then
|
||||
vim.lsp.inlay_hint.enable(true, { bufnr = args.buf })
|
||||
end
|
||||
end,
|
||||
})
|
||||
|
||||
@@ -0,0 +1,13 @@
|
||||
vim.schedule(function()
|
||||
vim.g.clipboard = {
|
||||
name = 'OSC 52',
|
||||
copy = {
|
||||
['+'] = require('vim.ui.clipboard.osc52').copy('+'),
|
||||
['*'] = require('vim.ui.clipboard.osc52').copy('*'),
|
||||
},
|
||||
paste = {
|
||||
['+'] = require('vim.ui.clipboard.osc52').paste('+'),
|
||||
['*'] = require('vim.ui.clipboard.osc52').paste('*'),
|
||||
},
|
||||
}
|
||||
end)
|
||||
+43
-11
@@ -1,16 +1,48 @@
|
||||
-- Window navigation
|
||||
vim.keymap.set('n', '<leader>`', '<C-^>', { noremap = true, silent = true })
|
||||
vim.keymap.set('n', '<leader>wh', '<C-w>h', { noremap = true, silent = true })
|
||||
vim.keymap.set('n', '<leader>wj', '<C-w>j', { noremap = true, silent = true })
|
||||
vim.keymap.set('n', '<leader>wk', '<C-w>k', { noremap = true, silent = true })
|
||||
vim.keymap.set('n', '<leader>wl', '<C-w>l', { noremap = true, silent = true })
|
||||
vim.keymap.set("n", "<leader>`", "<C-^>", { noremap = true, silent = true })
|
||||
vim.keymap.set("n", "<leader>wh", "<C-w>h", { noremap = true, silent = true })
|
||||
vim.keymap.set("n", "<leader>wj", "<C-w>j", { noremap = true, silent = true })
|
||||
vim.keymap.set("n", "<leader>wk", "<C-w>k", { noremap = true, silent = true })
|
||||
vim.keymap.set("n", "<leader>wl", "<C-w>l", { noremap = true, silent = true })
|
||||
|
||||
vim.keymap.set({ "n", "v" }, "<leader>y", '"+y')
|
||||
|
||||
-- Buffer navigation
|
||||
vim.keymap.set('n', '<C-j>', '1<C-e>', { noremap = true, silent = true })
|
||||
vim.keymap.set('n', '<C-k>', '1<C-y>', { noremap = true, silent = true })
|
||||
-- vim.keymap.set('n', '<C-j>', '1<C-e>', { noremap = true, silent = true })
|
||||
-- vim.keymap.set('n', '<C-k>', '1<C-y>', { noremap = true, silent = true })
|
||||
|
||||
-- Editor
|
||||
vim.keymap.set("i", "<D-v>", "<C-r>+", { noremap = true, silent = true, desc = "Paste from system clipboard" })
|
||||
|
||||
-- LSP
|
||||
vim.keymap.set('n', '<leader>ld', vim.diagnostic.open_float, { noremap = true, silent = true, desc = "Open diagnostics float" })
|
||||
vim.keymap.set('n', '<leader>lo', vim.lsp.buf.code_action, { noremap = true, silent = true, desc = "LSP Code Action" })
|
||||
vim.keymap.set('n', '<leader>li', vim.diagnostic.setqflist, { noremap = true, silent = true, desc = "LSP Diagnostics to QF" })
|
||||
vim.keymap.set('n', '<F2>', vim.lsp.buf.rename, { noremap = true, silent = true, desc = "LSP Rename" })
|
||||
vim.keymap.set(
|
||||
"n",
|
||||
"<leader>ld",
|
||||
vim.diagnostic.open_float,
|
||||
{ noremap = true, silent = true, desc = "Open diagnostics float" }
|
||||
)
|
||||
vim.keymap.set("n", "<leader>lo", vim.lsp.buf.code_action, { noremap = true, silent = true, desc = "LSP Code Action" })
|
||||
vim.keymap.set(
|
||||
"n",
|
||||
"<leader>li",
|
||||
vim.diagnostic.setqflist,
|
||||
{ noremap = true, silent = true, desc = "LSP Diagnostics to QF" }
|
||||
)
|
||||
vim.keymap.set("n", "gd", vim.lsp.buf.definition, { noremap = true, silent = true, desc = "LSP Go to Definition" })
|
||||
vim.keymap.set("n", "<F2>", vim.lsp.buf.rename, { noremap = true, silent = true, desc = "LSP Rename" })
|
||||
|
||||
-- glances.nvim
|
||||
vim.keymap.set("n", "gD", "<CMD>Glance definitions<CR>")
|
||||
vim.keymap.set("n", "gR", "<CMD>Glance references<CR>")
|
||||
vim.keymap.set("n", "gY", "<CMD>Glance type_definitions<CR>")
|
||||
vim.keymap.set("n", "gM", "<CMD>Glance implementations<CR>")
|
||||
|
||||
-- Snacks Terminal
|
||||
vim.keymap.set("n", "<leader>tV", function()
|
||||
local snacks = require("snacks")
|
||||
snacks.terminal.open(nil, { win = { position = "right" } })
|
||||
end, { desc = "Terminal (Vertical Split)" })
|
||||
vim.keymap.set("n", "<leader>tS", function()
|
||||
local snacks = require("snacks")
|
||||
snacks.terminal.open(nil, { win = { position = "bottom" } })
|
||||
end, { desc = "Terminal (Horizontal Split)" })
|
||||
|
||||
+12
-11
@@ -13,12 +13,12 @@ local M = {
|
||||
enabled = true,
|
||||
auto_trigger = true,
|
||||
keymap = {
|
||||
accept = "<M-j>",
|
||||
accept_line = "<M-l>",
|
||||
accept_word = "<M-k>",
|
||||
next = "<M-]>",
|
||||
prev = "<M-[>",
|
||||
dismiss = "<M-c>",
|
||||
accept = "<C-j>",
|
||||
accept_line = "<C-l>",
|
||||
accept_word = "<C-k>",
|
||||
-- next = "<C-]>",
|
||||
-- prev = "<C-[>",
|
||||
dismiss = "<C-c>",
|
||||
},
|
||||
},
|
||||
nes = {
|
||||
@@ -52,12 +52,13 @@ local M = {
|
||||
end,
|
||||
},
|
||||
{
|
||||
"CopilotC-Nvim/CopilotChat.nvim",
|
||||
dependencies = {
|
||||
{ "nvim-lua/plenary.nvim", branch = "master" },
|
||||
},
|
||||
build = "make tiktoken",
|
||||
"olimorris/codecompanion.nvim",
|
||||
version = "^19.0.0",
|
||||
opts = {},
|
||||
dependencies = {
|
||||
"nvim-lua/plenary.nvim",
|
||||
"nvim-treesitter/nvim-treesitter",
|
||||
},
|
||||
},
|
||||
}
|
||||
|
||||
|
||||
@@ -5,14 +5,84 @@ local M = {
|
||||
priority = 1000,
|
||||
opts = {},
|
||||
},
|
||||
{
|
||||
"gmr458/vscode_modern_theme.nvim",
|
||||
lazy = false,
|
||||
priority = 1000,
|
||||
config = function()
|
||||
require("vscode_modern").setup({
|
||||
cursorline = true,
|
||||
transparent_background = false,
|
||||
nvim_tree_darker = true,
|
||||
})
|
||||
vim.cmd.colorscheme("vscode_modern")
|
||||
end,
|
||||
},
|
||||
{ "nvim-tree/nvim-web-devicons", opts = {} },
|
||||
{
|
||||
"https://github.com/nvim-lualine/lualine.nvim",
|
||||
event = "VeryLazy",
|
||||
config = function()
|
||||
require("lualine").setup()
|
||||
local function window_number()
|
||||
return vim.api.nvim_win_get_number(0)
|
||||
end
|
||||
|
||||
require("lualine").setup({
|
||||
options = {
|
||||
icons_enabled = true,
|
||||
theme = "auto",
|
||||
component_separators = { left = "", right = "" },
|
||||
section_separators = { left = "", right = "" },
|
||||
disabled_filetypes = {
|
||||
statusline = {},
|
||||
winbar = {},
|
||||
},
|
||||
ignore_focus = {},
|
||||
always_divide_middle = true,
|
||||
always_show_tabline = true,
|
||||
globalstatus = false,
|
||||
refresh = {
|
||||
statusline = 1000,
|
||||
tabline = 1000,
|
||||
winbar = 1000,
|
||||
refresh_time = 16, -- ~60fps
|
||||
events = {
|
||||
"WinEnter",
|
||||
"BufEnter",
|
||||
"BufWritePost",
|
||||
"SessionLoadPost",
|
||||
"FileChangedShellPost",
|
||||
"VimResized",
|
||||
"Filetype",
|
||||
"CursorMoved",
|
||||
"CursorMovedI",
|
||||
"ModeChanged",
|
||||
},
|
||||
},
|
||||
},
|
||||
sections = {
|
||||
lualine_a = { "mode" },
|
||||
lualine_b = { "branch", "diff", "diagnostics" },
|
||||
lualine_c = { "filename" },
|
||||
lualine_x = { "encoding", "fileformat", "filetype" },
|
||||
lualine_y = { window_number, "progress" },
|
||||
lualine_z = { "location" },
|
||||
},
|
||||
inactive_sections = {
|
||||
lualine_a = {},
|
||||
lualine_b = {},
|
||||
lualine_c = { "filename" },
|
||||
lualine_x = { window_number, "location" },
|
||||
lualine_y = {},
|
||||
lualine_z = {},
|
||||
},
|
||||
tabline = {},
|
||||
winbar = {},
|
||||
inactive_winbar = {},
|
||||
extensions = {},
|
||||
})
|
||||
end,
|
||||
},
|
||||
}
|
||||
|
||||
return M
|
||||
return M
|
||||
|
||||
@@ -0,0 +1,27 @@
|
||||
local M = {
|
||||
{
|
||||
"mfussenegger/nvim-dap",
|
||||
lazy = true,
|
||||
dependencies = {
|
||||
"rcarriga/nvim-dap-ui",
|
||||
},
|
||||
keys = {
|
||||
{
|
||||
"<leader>d",
|
||||
function()
|
||||
require("dap").toggle_breakpoint()
|
||||
end,
|
||||
},
|
||||
{
|
||||
"<leader>c",
|
||||
function()
|
||||
require("dap").continue()
|
||||
end,
|
||||
},
|
||||
},
|
||||
config = function()
|
||||
require("dapui").setup()
|
||||
end,
|
||||
},
|
||||
}
|
||||
return M
|
||||
+27
-13
@@ -56,6 +56,16 @@ local M = {
|
||||
require("Comment").setup()
|
||||
end,
|
||||
},
|
||||
{
|
||||
"Aasim-A/scrollEOF.nvim",
|
||||
event = { "CursorMoved", "WinScrolled" },
|
||||
opts = {},
|
||||
},
|
||||
{
|
||||
"folke/todo-comments.nvim",
|
||||
dependencies = { "nvim-lua/plenary.nvim" },
|
||||
opts = {}
|
||||
},
|
||||
{
|
||||
"folke/flash.nvim",
|
||||
event = "VeryLazy",
|
||||
@@ -101,19 +111,23 @@ local M = {
|
||||
desc = "Toggle Flash Search",
|
||||
},
|
||||
},
|
||||
config = function()
|
||||
require("flash").setup({
|
||||
modes = {
|
||||
search = {
|
||||
enabled = true,
|
||||
},
|
||||
char = {
|
||||
enabled = true,
|
||||
jump_labels = true,
|
||||
},
|
||||
}
|
||||
})
|
||||
end,
|
||||
config = function()
|
||||
require("flash").setup({
|
||||
modes = {
|
||||
search = {
|
||||
enabled = true,
|
||||
},
|
||||
char = {
|
||||
enabled = true,
|
||||
jump_labels = true,
|
||||
multi_line = false,
|
||||
jump = {
|
||||
autojump = true,
|
||||
},
|
||||
},
|
||||
},
|
||||
})
|
||||
end,
|
||||
},
|
||||
{
|
||||
"folke/snacks.nvim",
|
||||
|
||||
+24
-1
@@ -11,6 +11,29 @@ local M = {
|
||||
{ "<leader>gg", "<cmd>Neogit<cr>", desc = "Show Neogit UI" },
|
||||
},
|
||||
},
|
||||
{
|
||||
"esmuellert/codediff.nvim",
|
||||
dependencies = { "MunifTanjim/nui.nvim" },
|
||||
cmd = "CodeDiff",
|
||||
},
|
||||
{
|
||||
"lewis6991/gitsigns.nvim",
|
||||
},
|
||||
{
|
||||
"akinsho/git-conflict.nvim",
|
||||
version = "*",
|
||||
config = function()
|
||||
require("git-conflict").setup({
|
||||
default_mappings = true, -- disable buffer local mapping created by this plugin
|
||||
default_commands = true, -- disable commands created by this plugin
|
||||
disable_diagnostics = true, -- This will disable the diagnostics in a buffer whilst it is conflicted
|
||||
highlights = {
|
||||
incoming = "DiffText",
|
||||
current = "DiffAdd",
|
||||
},
|
||||
})
|
||||
end,
|
||||
},
|
||||
}
|
||||
|
||||
return M
|
||||
return M
|
||||
|
||||
@@ -0,0 +1,84 @@
|
||||
local M = {
|
||||
{
|
||||
"TheNoeTrevino/haunt.nvim",
|
||||
-- default config: change to your liking, or remove it to use defaults
|
||||
---@class HauntConfig
|
||||
opts = {
|
||||
sign = "",
|
||||
sign_hl = "DiagnosticInfo",
|
||||
virt_text_hl = "HauntAnnotation", -- links to DiagnosticVirtualTextHint
|
||||
annotation_prefix = " ",
|
||||
annotation_suffix = "",
|
||||
line_hl = nil,
|
||||
virt_text_pos = "eol",
|
||||
data_dir = nil,
|
||||
per_branch_bookmarks = true,
|
||||
picker = "auto", -- "auto", "snacks", "telescope", or "fzf"
|
||||
picker_keys = { -- picker agnostic, we got you covered
|
||||
delete = { key = "d", mode = { "n" } },
|
||||
edit_annotation = { key = "a", mode = { "n" } },
|
||||
},
|
||||
},
|
||||
-- recommended keymaps, with a helpful prefix alias
|
||||
init = function()
|
||||
local haunt = require("haunt.api")
|
||||
local haunt_picker = require("haunt.picker")
|
||||
local map = vim.keymap.set
|
||||
local prefix = "<leader>h"
|
||||
|
||||
-- annotations
|
||||
map("n", prefix .. "a", function()
|
||||
haunt.annotate()
|
||||
end, { desc = "Annotate" })
|
||||
|
||||
map("n", prefix .. "t", function()
|
||||
haunt.toggle_annotation()
|
||||
end, { desc = "Toggle annotation" })
|
||||
|
||||
map("n", prefix .. "T", function()
|
||||
haunt.toggle_all_lines()
|
||||
end, { desc = "Toggle all annotations" })
|
||||
|
||||
map("n", prefix .. "d", function()
|
||||
haunt.delete()
|
||||
end, { desc = "Delete bookmark" })
|
||||
|
||||
map("n", prefix .. "C", function()
|
||||
haunt.clear_all()
|
||||
end, { desc = "Delete all bookmarks" })
|
||||
|
||||
-- move
|
||||
map("n", prefix .. "p", function()
|
||||
haunt.prev()
|
||||
end, { desc = "Previous bookmark" })
|
||||
|
||||
map("n", prefix .. "n", function()
|
||||
haunt.next()
|
||||
end, { desc = "Next bookmark" })
|
||||
|
||||
-- picker
|
||||
map("n", prefix .. "l", function()
|
||||
haunt_picker.show()
|
||||
end, { desc = "Show Picker" })
|
||||
|
||||
-- quickfix
|
||||
map("n", prefix .. "q", function()
|
||||
haunt.to_quickfix()
|
||||
end, { desc = "Send Hauntings to QF Lix (buffer)" })
|
||||
|
||||
map("n", prefix .. "Q", function()
|
||||
haunt.to_quickfix({ current_buffer = true })
|
||||
end, { desc = "Send Hauntings to QF Lix (all)" })
|
||||
|
||||
-- yank
|
||||
map("n", prefix .. "y", function()
|
||||
haunt.yank_locations({ current_buffer = true })
|
||||
end, { desc = "Send Hauntings to Clipboard (buffer)" })
|
||||
|
||||
map("n", prefix .. "Y", function()
|
||||
haunt.yank_locations()
|
||||
end, { desc = "Send Hauntings to Clipboard (all)" })
|
||||
end,
|
||||
},
|
||||
}
|
||||
return M
|
||||
+86
-16
@@ -7,8 +7,69 @@ local M = {
|
||||
vim.lsp.enable("luals")
|
||||
vim.lsp.enable("sqls")
|
||||
vim.lsp.enable("ty")
|
||||
vim.lsp.enable("svelte")
|
||||
|
||||
-- Setup gopls with inlay hints
|
||||
vim.lsp.config("gopls", {
|
||||
settings = {
|
||||
gopls = {
|
||||
hints = {
|
||||
assignVariableTypes = true,
|
||||
compositeLiteralFields = true,
|
||||
compositeLiteralTypes = true,
|
||||
constantValues = true,
|
||||
functionTypeParameters = true,
|
||||
parameterNames = true,
|
||||
rangeVariableTypes = true,
|
||||
},
|
||||
},
|
||||
},
|
||||
})
|
||||
vim.lsp.enable("gopls")
|
||||
end,
|
||||
},
|
||||
{
|
||||
"mfussenegger/nvim-jdtls",
|
||||
config = function()
|
||||
local config = {
|
||||
cmd = {
|
||||
"java",
|
||||
"-Xmx20g",
|
||||
"-Xms1g",
|
||||
"-Declipse.application=org.eclipse.jdt.ls.core.id1",
|
||||
},
|
||||
}
|
||||
|
||||
vim.lsp.enable("jdtls")
|
||||
end,
|
||||
},
|
||||
{
|
||||
"ray-x/go.nvim",
|
||||
dependencies = {
|
||||
"ray-x/guihua.lua",
|
||||
"neovim/nvim-lspconfig",
|
||||
},
|
||||
opts = {
|
||||
lsp_inlay_hints = {
|
||||
enable = true, -- This tells go.nvim to manage the Neovim-side toggle
|
||||
},
|
||||
},
|
||||
config = function(_, opts)
|
||||
require("go").setup(opts)
|
||||
|
||||
-- Custom autocommands should go here
|
||||
local format_sync_grp = vim.api.nvim_create_augroup("GoFormat", {})
|
||||
vim.api.nvim_create_autocmd("BufWritePre", {
|
||||
pattern = "*.go",
|
||||
callback = function()
|
||||
require("go.format").goimports()
|
||||
end,
|
||||
group = format_sync_grp,
|
||||
})
|
||||
end,
|
||||
event = { "CmdlineEnter" },
|
||||
ft = { "go", "gomod" },
|
||||
},
|
||||
{
|
||||
"saghen/blink.cmp",
|
||||
dependencies = { "rafamadriz/friendly-snippets" },
|
||||
@@ -51,9 +112,9 @@ local M = {
|
||||
sources = {
|
||||
-- add lazydev to your completion providers
|
||||
default = { "lazydev", "lsp", "path", "snippets", "buffer" },
|
||||
per_filetype = {
|
||||
org = { "orgmode" }
|
||||
},
|
||||
per_filetype = {
|
||||
org = { "orgmode" },
|
||||
},
|
||||
providers = {
|
||||
lazydev = {
|
||||
name = "LazyDev",
|
||||
@@ -61,11 +122,11 @@ local M = {
|
||||
-- make lazydev completions top priority (see `:h blink.cmp`)
|
||||
score_offset = 100,
|
||||
},
|
||||
orgmode = {
|
||||
name = "Orgmode",
|
||||
module = "orgmode.org.autocompletion.blink",
|
||||
fallbacks = { "buffer" },
|
||||
}
|
||||
orgmode = {
|
||||
name = "Orgmode",
|
||||
module = "orgmode.org.autocompletion.blink",
|
||||
fallbacks = { "buffer" },
|
||||
},
|
||||
},
|
||||
},
|
||||
|
||||
@@ -75,9 +136,14 @@ local M = {
|
||||
--
|
||||
-- See the fuzzy documentation for more information
|
||||
fuzzy = { implementation = "prefer_rust_with_warning" },
|
||||
signature = { enabled = true },
|
||||
},
|
||||
opts_extend = { "sources.default" },
|
||||
},
|
||||
{
|
||||
"mason-org/mason.nvim",
|
||||
opts = {},
|
||||
},
|
||||
{
|
||||
"folke/lazydev.nvim",
|
||||
ft = "lua",
|
||||
@@ -112,15 +178,19 @@ local M = {
|
||||
})
|
||||
end
|
||||
require("ufo").setup({
|
||||
provider_selector = function(bufnr, filetype, buftype)
|
||||
local ftMap = {
|
||||
org = "treesitter",
|
||||
}
|
||||
return ftMap[filetype] or {"treesitter", "indent"}
|
||||
end
|
||||
})
|
||||
provider_selector = function(bufnr, filetype, buftype)
|
||||
local ftMap = {
|
||||
org = "treesitter",
|
||||
}
|
||||
return ftMap[filetype] or { "treesitter", "indent" }
|
||||
end,
|
||||
})
|
||||
end,
|
||||
}
|
||||
},
|
||||
{
|
||||
"dnlhc/glance.nvim",
|
||||
cmd = "Glance",
|
||||
},
|
||||
}
|
||||
|
||||
return M
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
local M = {
|
||||
{
|
||||
"nvim-treesitter/nvim-treesitter",
|
||||
branch = "main",
|
||||
build = ":TSUpdate",
|
||||
config = function()
|
||||
local ensureInstalled = {
|
||||
@@ -10,6 +11,7 @@ local M = {
|
||||
"typescript",
|
||||
"java",
|
||||
"go",
|
||||
"java",
|
||||
"rust",
|
||||
"html",
|
||||
"css",
|
||||
@@ -17,6 +19,7 @@ local M = {
|
||||
"yaml",
|
||||
"markdown",
|
||||
"sql",
|
||||
"svelte",
|
||||
"org",
|
||||
}
|
||||
local alreadyInstalled = require("nvim-treesitter.config").get_installed()
|
||||
|
||||
Reference in New Issue
Block a user