mirror of
https://github.com/tiyn/dotfiles.git
synced 2026-03-28 10:24:47 +01:00
NVIM: Split opts and config for lazy plugins
This commit is contained in:
@@ -10,18 +10,16 @@ return {
|
|||||||
desc = "LSP: format",
|
desc = "LSP: format",
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
config = function()
|
opts = {
|
||||||
require("conform").setup({
|
formatters_by_ft = {
|
||||||
formatters_by_ft = {
|
lua = { "stylua" },
|
||||||
lua = { "stylua" },
|
markdown = { "mdformat" },
|
||||||
markdown = { "mdformat" },
|
python = { "isort", "yapf" },
|
||||||
python = { "isort", "yapf" },
|
sh = { "shfmt" },
|
||||||
sh = { "shfmt" },
|
bash = { "shfmt" },
|
||||||
bash = { "shfmt" },
|
zsh = { "shfmt" },
|
||||||
zsh = { "shfmt" },
|
tex = { "latexindent" },
|
||||||
tex = { "latexindent" },
|
yaml = { "yamlfmt" },
|
||||||
yaml = { "yamlfmt" },
|
},
|
||||||
},
|
},
|
||||||
})
|
|
||||||
end,
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -3,18 +3,20 @@ return {
|
|||||||
"hat0uma/csvview.nvim",
|
"hat0uma/csvview.nvim",
|
||||||
ft = "csv",
|
ft = "csv",
|
||||||
cmd = { "CsvViewEnable", "CsvViewDisable", "CsvViewToggle" },
|
cmd = { "CsvViewEnable", "CsvViewDisable", "CsvViewToggle" },
|
||||||
config = function()
|
opts = {
|
||||||
require("csvview").setup({
|
parser = { comments = { "#", "//" } },
|
||||||
parser = { comments = { "#", "//" } },
|
keymaps = {
|
||||||
keymaps = {
|
textobject_field_inner = { "if", mode = { "o", "x" } },
|
||||||
textobject_field_inner = { "if", mode = { "o", "x" } },
|
textobject_field_outer = { "af", mode = { "o", "x" } },
|
||||||
textobject_field_outer = { "af", mode = { "o", "x" } },
|
jump_next_field_end = { "<Tab>", mode = { "n", "v" } },
|
||||||
jump_next_field_end = { "<Tab>", mode = { "n", "v" } },
|
jump_prev_field_end = { "<S-Tab>", mode = { "n", "v" } },
|
||||||
jump_prev_field_end = { "<S-Tab>", mode = { "n", "v" } },
|
jump_next_row = { "<Enter>", mode = { "n", "v" } },
|
||||||
jump_next_row = { "<Enter>", mode = { "n", "v" } },
|
jump_prev_row = { "<S-Enter>", mode = { "n", "v" } },
|
||||||
jump_prev_row = { "<S-Enter>", mode = { "n", "v" } },
|
},
|
||||||
},
|
},
|
||||||
})
|
config = function(_, opts)
|
||||||
require("csvview").enable()
|
local csvview = require("csvview")
|
||||||
|
csvview.setup(opts)
|
||||||
|
csvview.enable()
|
||||||
end,
|
end,
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -46,19 +46,17 @@ return {
|
|||||||
desc = "LSP: close all preview windows",
|
desc = "LSP: close all preview windows",
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
config = function()
|
opts = {
|
||||||
require("goto-preview").setup({
|
border = "rounded",
|
||||||
border = "rounded",
|
preview_window_title = { enable = true, position = "center" },
|
||||||
preview_window_title = { enable = true, position = "center" },
|
|
||||||
|
|
||||||
post_open_hook = function(bufnr, winid)
|
post_open_hook = function(bufnr, _)
|
||||||
local close = function()
|
local close = function()
|
||||||
require("goto-preview").close_all_win()
|
require("goto-preview").close_all_win()
|
||||||
end
|
end
|
||||||
|
|
||||||
vim.keymap.set("n", "<c-h>", close, { buffer = bufnr, silent = true })
|
vim.keymap.set("n", "<c-h>", close, { buffer = bufnr, silent = true })
|
||||||
vim.keymap.set("n", "q", close, { buffer = bufnr, silent = true })
|
vim.keymap.set("n", "q", close, { buffer = bufnr, silent = true })
|
||||||
end,
|
end,
|
||||||
})
|
},
|
||||||
end,
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -4,9 +4,7 @@ return {
|
|||||||
keys = {
|
keys = {
|
||||||
{
|
{
|
||||||
"<leader>p",
|
"<leader>p",
|
||||||
function()
|
function() require("knap").toggle_autopreviewing() end,
|
||||||
require("knap").toggle_autopreviewing()
|
|
||||||
end,
|
|
||||||
desc = "Knap: toggle autopreview",
|
desc = "Knap: toggle autopreview",
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
|||||||
@@ -2,17 +2,14 @@ return {
|
|||||||
-- statusline
|
-- statusline
|
||||||
"nvim-lualine/lualine.nvim",
|
"nvim-lualine/lualine.nvim",
|
||||||
dependencies = {
|
dependencies = {
|
||||||
{
|
"nvim-tree/nvim-web-devicons",
|
||||||
"nvim-tree/nvim-web-devicons",
|
"tiyn/tccs.nvim",
|
||||||
lazy = true,
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
"f-person/git-blame.nvim",
|
"f-person/git-blame.nvim",
|
||||||
config = function()
|
config = function()
|
||||||
vim.g.gitblame_display_virtual_text = 0
|
vim.g.gitblame_display_virtual_text = 0
|
||||||
end,
|
end,
|
||||||
},
|
},
|
||||||
{ "tiyn/tccs.nvim" },
|
|
||||||
{
|
{
|
||||||
"tiyn/action-hints.nvim",
|
"tiyn/action-hints.nvim",
|
||||||
config = function()
|
config = function()
|
||||||
@@ -27,54 +24,58 @@ return {
|
|||||||
end,
|
end,
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
config = function()
|
opts = {
|
||||||
require("lualine").setup({
|
options = {
|
||||||
options = {
|
globalstatus = true,
|
||||||
globalstatus = true,
|
symbols = {
|
||||||
symbols = {
|
error = Error_sign,
|
||||||
error = Error_sign,
|
warn = Warn_sign,
|
||||||
warn = Warn_sign,
|
hint = Hint_sign,
|
||||||
hint = Hint_sign,
|
info = Info_sign,
|
||||||
info = Info_sign,
|
|
||||||
},
|
|
||||||
theme = "tccs",
|
|
||||||
component_separators = { left = "", right = "" },
|
|
||||||
section_separators = { left = "", right = "" },
|
|
||||||
},
|
},
|
||||||
sections = {
|
theme = "tccs",
|
||||||
lualine_b = {
|
component_separators = { left = "", right = "" },
|
||||||
{
|
section_separators = { left = "", right = "" },
|
||||||
require("gitblame").get_current_blame_text,
|
},
|
||||||
cond = require("gitblame").is_blame_text_available,
|
sections = {
|
||||||
},
|
lualine_b = {
|
||||||
|
{
|
||||||
|
function()
|
||||||
|
return require("gitblame").get_current_blame_text()
|
||||||
|
end,
|
||||||
|
cond = function()
|
||||||
|
return require("gitblame").is_blame_text_available()
|
||||||
|
end,
|
||||||
},
|
},
|
||||||
lualine_c = {},
|
|
||||||
lualine_x = {
|
|
||||||
require("action-hints").statusline,
|
|
||||||
"encoding",
|
|
||||||
"fileformat",
|
|
||||||
{
|
|
||||||
"filetype",
|
|
||||||
icon_only = true,
|
|
||||||
},
|
|
||||||
},
|
|
||||||
lualine_y = {
|
|
||||||
{
|
|
||||||
"filename",
|
|
||||||
file_status = true,
|
|
||||||
newfile_status = true,
|
|
||||||
path = 1,
|
|
||||||
shorting_target = 50,
|
|
||||||
symbols = {
|
|
||||||
modified = Lualine_signs["modified"],
|
|
||||||
readonly = Lualine_signs["readonly"],
|
|
||||||
unnamed = Lualine_signs["unnamed"],
|
|
||||||
newfile = Lualine_signs["newfile"],
|
|
||||||
},
|
|
||||||
},
|
|
||||||
},
|
|
||||||
lualine_z = { "progress", "location" },
|
|
||||||
},
|
},
|
||||||
})
|
lualine_c = {},
|
||||||
end,
|
lualine_x = {
|
||||||
|
function()
|
||||||
|
return require("action-hints").statusline()
|
||||||
|
end,
|
||||||
|
"encoding",
|
||||||
|
"fileformat",
|
||||||
|
{
|
||||||
|
"filetype",
|
||||||
|
icon_only = true,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
lualine_y = {
|
||||||
|
{
|
||||||
|
"filename",
|
||||||
|
file_status = true,
|
||||||
|
newfile_status = true,
|
||||||
|
path = 1,
|
||||||
|
shorting_target = 50,
|
||||||
|
symbols = {
|
||||||
|
modified = Lualine_signs["modified"],
|
||||||
|
readonly = Lualine_signs["readonly"],
|
||||||
|
unnamed = Lualine_signs["unnamed"],
|
||||||
|
newfile = Lualine_signs["newfile"],
|
||||||
|
},
|
||||||
|
},
|
||||||
|
},
|
||||||
|
lualine_z = { "progress", "location" },
|
||||||
|
},
|
||||||
|
},
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,7 +1,5 @@
|
|||||||
return {
|
return {
|
||||||
-- decorations for the current line mode
|
-- decorations for the current line mode
|
||||||
"mvllow/modes.nvim",
|
"mvllow/modes.nvim",
|
||||||
config = function()
|
opts = {},
|
||||||
require("modes").setup()
|
|
||||||
end,
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -65,28 +65,30 @@ return {
|
|||||||
desc = "Quarto: Run all cells of all languages",
|
desc = "Quarto: Run all cells of all languages",
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
config = function()
|
opts = {
|
||||||
require("quarto").setup({
|
lspFeatures = {
|
||||||
lspFeatures = {
|
languages = { "python" },
|
||||||
languages = { "python" },
|
chunks = "all",
|
||||||
chunks = "all",
|
diagnostics = {
|
||||||
diagnostics = {
|
|
||||||
enabled = true,
|
|
||||||
triggers = { "BufWritePost" },
|
|
||||||
},
|
|
||||||
completion = {
|
|
||||||
enabled = true,
|
|
||||||
},
|
|
||||||
},
|
|
||||||
codeRunner = {
|
|
||||||
enabled = true,
|
enabled = true,
|
||||||
default_method = "molten",
|
triggers = { "BufWritePost" },
|
||||||
},
|
},
|
||||||
})
|
completion = {
|
||||||
|
enabled = true,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
codeRunner = {
|
||||||
|
enabled = true,
|
||||||
|
default_method = "molten",
|
||||||
|
},
|
||||||
|
},
|
||||||
|
config = function(_, opts)
|
||||||
|
local quarto = require("quarto")
|
||||||
|
quarto.setup(opts)
|
||||||
vim.api.nvim_create_autocmd("FileType", {
|
vim.api.nvim_create_autocmd("FileType", {
|
||||||
pattern = "markdown",
|
pattern = "markdown",
|
||||||
callback = function()
|
callback = function()
|
||||||
require("quarto").activate()
|
quarto.activate()
|
||||||
end,
|
end,
|
||||||
})
|
})
|
||||||
end,
|
end,
|
||||||
|
|||||||
@@ -17,7 +17,7 @@ return {
|
|||||||
end,
|
end,
|
||||||
version = "v2.*",
|
version = "v2.*",
|
||||||
-- build = "make install_jsregexp",
|
-- build = "make install_jsregexp",
|
||||||
dependencies = { "saadparwaiz1/cmp_luasnip" },
|
dependencies = "saadparwaiz1/cmp_luasnip",
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
config = function()
|
config = function()
|
||||||
|
|||||||
@@ -3,31 +3,33 @@ return {
|
|||||||
"martineausimon/nvim-lilypond-suite",
|
"martineausimon/nvim-lilypond-suite",
|
||||||
ft = "lilypond",
|
ft = "lilypond",
|
||||||
dependencies = "uga-rosa/cmp-dictionary",
|
dependencies = "uga-rosa/cmp-dictionary",
|
||||||
config = function()
|
opts = {
|
||||||
require("nvls").setup({
|
lilypond = {
|
||||||
lilypond = {
|
mappings = {
|
||||||
mappings = {
|
player = "<NOP>",
|
||||||
player = "<NOP>",
|
compile = "<NOP>",
|
||||||
compile = "<NOP>",
|
open_pdf = "<NOP>",
|
||||||
open_pdf = "<NOP>",
|
switch_buffers = "<NOP>",
|
||||||
switch_buffers = "<NOP>",
|
insert_version = "<NOP>",
|
||||||
insert_version = "<NOP>",
|
hyphenation = "<NOP>",
|
||||||
hyphenation = "<NOP>",
|
hyphenation_change_lang = "<NOP>",
|
||||||
hyphenation_change_lang = "<NOP>",
|
insert_hyphen = "<NOP>",
|
||||||
insert_hyphen = "<NOP>",
|
add_hyphen = "<NOP>",
|
||||||
add_hyphen = "<NOP>",
|
del_next_hyphen = "<NOP>",
|
||||||
del_next_hyphen = "<NOP>",
|
del_prev_hyphen = "<NOP>",
|
||||||
del_prev_hyphen = "<NOP>",
|
},
|
||||||
|
},
|
||||||
|
player = {
|
||||||
|
options = {
|
||||||
|
fluidsynth_flags = {
|
||||||
|
"/usr/share/soundfonts/FluidR3_GM.sf2",
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
player = {
|
},
|
||||||
options = {
|
},
|
||||||
fluidsynth_flags = {
|
config = function(_, opts)
|
||||||
"/usr/share/soundfonts/FluidR3_GM.sf2",
|
local nvls = require("nvls")
|
||||||
},
|
nvls.setup(opts)
|
||||||
},
|
|
||||||
},
|
|
||||||
})
|
|
||||||
local lily_dicts = {
|
local lily_dicts = {
|
||||||
"~/.local/share/nvim/lazy/nvim-lilypond-suite/lilywords/keywords",
|
"~/.local/share/nvim/lazy/nvim-lilypond-suite/lilywords/keywords",
|
||||||
"~/.local/share/nvim/lazy/nvim-lilypond-suite/lilywords/musicCommands",
|
"~/.local/share/nvim/lazy/nvim-lilypond-suite/lilywords/musicCommands",
|
||||||
@@ -37,59 +39,52 @@ return {
|
|||||||
}
|
}
|
||||||
vim.api.nvim_create_autocmd("FileType", {
|
vim.api.nvim_create_autocmd("FileType", {
|
||||||
pattern = "lilypond",
|
pattern = "lilypond",
|
||||||
callback = function()
|
callback = function(args)
|
||||||
|
local bufnr = args.buf
|
||||||
require("cmp_dictionary").setup({
|
require("cmp_dictionary").setup({
|
||||||
paths = lily_dicts,
|
paths = lily_dicts,
|
||||||
})
|
})
|
||||||
|
local fluidsynth_job = nil
|
||||||
|
vim.keymap.set("n", "<leader>pm", function()
|
||||||
|
local midi = vim.fn.expand("%:r") .. ".midi"
|
||||||
|
if fluidsynth_job then
|
||||||
|
vim.fn.jobstop(fluidsynth_job)
|
||||||
|
fluidsynth_job = nil
|
||||||
|
print("fluidsynth stopped")
|
||||||
|
return
|
||||||
|
end
|
||||||
|
fluidsynth_job = vim.fn.jobstart({ "fluidsynth", "-i", midi })
|
||||||
|
print("fluidsynth playing (Ctrl-C to stop)")
|
||||||
|
end, {
|
||||||
|
buffer = bufnr,
|
||||||
|
desc = "Lilypond: output MIDI",
|
||||||
|
})
|
||||||
|
vim.keymap.set("n", "<leader>pp", "<cmd>Viewer<CR>", {
|
||||||
|
buffer = bufnr,
|
||||||
|
desc = "Lilypond: open PDF",
|
||||||
|
})
|
||||||
|
vim.keymap.set("n", "<C-c>", function()
|
||||||
|
if fluidsynth_job then
|
||||||
|
vim.fn.jobstop(fluidsynth_job)
|
||||||
|
fluidsynth_job = nil
|
||||||
|
print("fluidsynth stopped")
|
||||||
|
else
|
||||||
|
vim.cmd("normal! <C-c>")
|
||||||
|
end
|
||||||
|
end, {
|
||||||
|
buffer = bufnr,
|
||||||
|
desc = "Stop MIDI playback",
|
||||||
|
})
|
||||||
|
if vim.b[bufnr].first_start_lilypond then
|
||||||
|
return
|
||||||
|
end
|
||||||
|
vim.b[bufnr].first_start_lilypond = true
|
||||||
|
vim.schedule(function()
|
||||||
|
if vim.fn.exists(":Viewer") == 2 then
|
||||||
|
vim.cmd.Viewer()
|
||||||
|
end
|
||||||
|
end)
|
||||||
end,
|
end,
|
||||||
})
|
})
|
||||||
|
|
||||||
local fluidsynth_job = nil
|
|
||||||
|
|
||||||
vim.keymap.set("n", "<leader>pm", function()
|
|
||||||
local midi = vim.fn.expand("%:r") .. ".midi"
|
|
||||||
|
|
||||||
if fluidsynth_job then
|
|
||||||
vim.fn.jobstop(fluidsynth_job)
|
|
||||||
fluidsynth_job = nil
|
|
||||||
print("fluidsynth stopped")
|
|
||||||
return
|
|
||||||
end
|
|
||||||
|
|
||||||
fluidsynth_job = vim.fn.jobstart({ "fluidsynth", "-i", midi })
|
|
||||||
print("fluidsynth playing (Ctrl-C to stop)")
|
|
||||||
end, {
|
|
||||||
buffer = bufnr,
|
|
||||||
desc = "Lilypond: output MIDI",
|
|
||||||
})
|
|
||||||
|
|
||||||
vim.keymap.set("n", "<leader>pp", "<cmd>Viewer<CR>", {
|
|
||||||
buffer = bufnr,
|
|
||||||
desc = "Lilypond: open PDF",
|
|
||||||
})
|
|
||||||
|
|
||||||
vim.keymap.set("n", "<C-c>", function()
|
|
||||||
if fluidsynth_job then
|
|
||||||
vim.fn.jobstop(fluidsynth_job)
|
|
||||||
fluidsynth_job = nil
|
|
||||||
print("fluidsynth stopped")
|
|
||||||
else
|
|
||||||
vim.cmd("normal! <C-c>")
|
|
||||||
end
|
|
||||||
end, {
|
|
||||||
buffer = bufnr,
|
|
||||||
desc = "Stop MIDI playback",
|
|
||||||
})
|
|
||||||
|
|
||||||
if vim.b.first_start_lilypond then
|
|
||||||
return
|
|
||||||
end
|
|
||||||
vim.b.first_start_lilypond = true
|
|
||||||
|
|
||||||
vim.schedule(function()
|
|
||||||
if vim.fn.exists(":Viewer") == 2 then
|
|
||||||
vim.cmd.Viewer()
|
|
||||||
end
|
|
||||||
end)
|
|
||||||
end,
|
end,
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -19,47 +19,32 @@ return {
|
|||||||
end,
|
end,
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
config = function()
|
opts = {
|
||||||
require("mason-lspconfig").setup({
|
automatic_setup = true,
|
||||||
automatic_setup = true,
|
ensure_installed = {
|
||||||
ensure_installed = {
|
"asm_lsp",
|
||||||
-- assembler
|
"clangd",
|
||||||
"asm_lsp",
|
"dockerls",
|
||||||
-- c
|
"gopls",
|
||||||
"clangd",
|
"html",
|
||||||
-- docker
|
"jsonls",
|
||||||
"dockerls",
|
"lemminx",
|
||||||
-- go
|
"ltex",
|
||||||
"gopls",
|
"texlab",
|
||||||
-- html
|
"lua_ls",
|
||||||
"html",
|
"marksman",
|
||||||
-- json
|
"nimls",
|
||||||
"jsonls",
|
"pyright",
|
||||||
-- xml
|
"r_language_server",
|
||||||
"lemminx",
|
"bashls",
|
||||||
-- latex
|
"sqlls",
|
||||||
"ltex",
|
"ts_ls",
|
||||||
"texlab",
|
"yamlls",
|
||||||
-- lua
|
},
|
||||||
"lua_ls",
|
},
|
||||||
-- markdown
|
config = function(_, opts)
|
||||||
"marksman",
|
local mason_lspconfig = require("mason-lspconfig")
|
||||||
-- nim
|
mason_lspconfig.setup(opts)
|
||||||
"nimls",
|
|
||||||
-- python
|
|
||||||
"pyright",
|
|
||||||
-- r
|
|
||||||
"r_language_server",
|
|
||||||
-- shell
|
|
||||||
"bashls",
|
|
||||||
-- sql
|
|
||||||
"sqlls",
|
|
||||||
-- typescript / javascript
|
|
||||||
"ts_ls",
|
|
||||||
-- yaml
|
|
||||||
"yamlls",
|
|
||||||
},
|
|
||||||
})
|
|
||||||
local default_flags = {
|
local default_flags = {
|
||||||
debounce_text_changes = 150,
|
debounce_text_changes = 150,
|
||||||
allow_incremental_sync = true,
|
allow_incremental_sync = true,
|
||||||
@@ -69,7 +54,6 @@ return {
|
|||||||
ltex = {
|
ltex = {
|
||||||
settings = {
|
settings = {
|
||||||
ltex = {
|
ltex = {
|
||||||
-- language = "de-DE",
|
|
||||||
enabled = { "latex", "markdown" },
|
enabled = { "latex", "markdown" },
|
||||||
dictionary = Dictionaries,
|
dictionary = Dictionaries,
|
||||||
},
|
},
|
||||||
@@ -95,10 +79,16 @@ return {
|
|||||||
})
|
})
|
||||||
)
|
)
|
||||||
end
|
end
|
||||||
vim.keymap.set("n", "gd", vim.lsp.buf.definition, opts)
|
vim.api.nvim_create_autocmd("LspAttach", {
|
||||||
vim.keymap.set("n", "gD", vim.lsp.buf.declaration, opts)
|
callback = function(args)
|
||||||
vim.keymap.set("n", "gT", vim.lsp.buf.type_definition, opts)
|
local bufnr = args.buf
|
||||||
vim.keymap.set("n", "gi", vim.lsp.buf.implementation, opts)
|
local opts = { buffer = bufnr }
|
||||||
vim.keymap.set("n", "gr", vim.lsp.buf.references, opts)
|
vim.keymap.set("n", "gd", vim.lsp.buf.definition, opts)
|
||||||
|
vim.keymap.set("n", "gD", vim.lsp.buf.declaration, opts)
|
||||||
|
vim.keymap.set("n", "gT", vim.lsp.buf.type_definition, opts)
|
||||||
|
vim.keymap.set("n", "gi", vim.lsp.buf.implementation, opts)
|
||||||
|
vim.keymap.set("n", "gr", vim.lsp.buf.references, opts)
|
||||||
|
end,
|
||||||
|
})
|
||||||
end,
|
end,
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -5,52 +5,34 @@ return {
|
|||||||
"kevinhwang91/nvim-hlslens",
|
"kevinhwang91/nvim-hlslens",
|
||||||
"lewis6991/gitsigns.nvim",
|
"lewis6991/gitsigns.nvim",
|
||||||
},
|
},
|
||||||
config = function()
|
opts = {
|
||||||
require("scrollbar").setup({
|
marks = {
|
||||||
marks = {
|
Cursor = { highlight = "Normal" },
|
||||||
Cursor = {
|
Search = { highlight = "Special" },
|
||||||
highlight = "Normal",
|
Error = { highlight = "DiagnosticSignError" },
|
||||||
},
|
Warn = { highlight = "DiagnosticSignWarn" },
|
||||||
Search = {
|
Info = { highlight = "DiagnosticSignInfo" },
|
||||||
highlight = "Special",
|
Hint = { highlight = "DiagnosticSignHint" },
|
||||||
},
|
Misc = { highlight = "Special" },
|
||||||
Error = {
|
GitAdd = { highlight = "GitGutterAdd" },
|
||||||
highlight = "DiagnosticSignError",
|
GitChange = { highlight = "GitGutterChange" },
|
||||||
},
|
GitDelete = { highlight = "GitGutterDelete" },
|
||||||
Warn = {
|
},
|
||||||
highlight = "DiagnosticSignWarn",
|
excluded_filetypes = {
|
||||||
},
|
"cmp_docs",
|
||||||
Info = {
|
"cmp_menu",
|
||||||
highlight = "DiagnosticSignInfo",
|
"noice",
|
||||||
},
|
"prompt",
|
||||||
Hint = {
|
"TelescopePrompt",
|
||||||
highlight = "DiagnosticSignHint",
|
"NvimTree",
|
||||||
},
|
"Navbuddy",
|
||||||
Misc = {
|
"FTerm",
|
||||||
highlight = "Special",
|
"",
|
||||||
},
|
},
|
||||||
GitAdd = {
|
},
|
||||||
highlight = "GitGutterAdd",
|
config = function(_, opts)
|
||||||
},
|
local scrollbar = require("scrollbar")
|
||||||
GitChange = {
|
scrollbar.setup(opts)
|
||||||
highlight = "GitGutterChange",
|
|
||||||
},
|
|
||||||
GitDelete = {
|
|
||||||
highlight = "GitGutterDelete",
|
|
||||||
},
|
|
||||||
},
|
|
||||||
excluded_filetypes = {
|
|
||||||
"cmp_docs",
|
|
||||||
"cmp_menu",
|
|
||||||
"noice",
|
|
||||||
"prompt",
|
|
||||||
"TelescopePrompt",
|
|
||||||
"NvimTree",
|
|
||||||
"Navbuddy",
|
|
||||||
"FTerm",
|
|
||||||
"",
|
|
||||||
},
|
|
||||||
})
|
|
||||||
require("scrollbar.handlers.search").setup()
|
require("scrollbar.handlers.search").setup()
|
||||||
require("scrollbar.handlers.gitsigns").setup()
|
require("scrollbar.handlers.gitsigns").setup()
|
||||||
end,
|
end,
|
||||||
|
|||||||
@@ -15,23 +15,21 @@ return {
|
|||||||
desc = "File tree: toggle",
|
desc = "File tree: toggle",
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
config = function()
|
opts = {
|
||||||
require("nvim-tree").setup({
|
sort_by = "case_sensitive",
|
||||||
sort_by = "case_sensitive",
|
view = {
|
||||||
view = {
|
width = 30,
|
||||||
width = 30,
|
},
|
||||||
},
|
filters = {
|
||||||
filters = {
|
dotfiles = true,
|
||||||
dotfiles = true,
|
},
|
||||||
},
|
renderer = {
|
||||||
renderer = {
|
group_empty = true,
|
||||||
group_empty = true,
|
icons = {
|
||||||
icons = {
|
glyphs = {
|
||||||
glyphs = {
|
git = Git_signs,
|
||||||
git = Git_signs,
|
|
||||||
},
|
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
})
|
},
|
||||||
end,
|
},
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -4,9 +4,16 @@ return {
|
|||||||
build = ":TSUpdate",
|
build = ":TSUpdate",
|
||||||
dependencies = {
|
dependencies = {
|
||||||
-- automatically close html-tags
|
-- automatically close html-tags
|
||||||
"windwp/nvim-ts-autotag",
|
{
|
||||||
-- color brackets
|
"windwp/nvim-ts-autotag",
|
||||||
-- 'p00f/nvim-ts-rainbow',
|
opts = {
|
||||||
|
opts = {
|
||||||
|
enable_close = true,
|
||||||
|
enable_rename = true,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
},
|
||||||
|
-- 'p00f/nvim-ts-rainbow', -- color brackets
|
||||||
"nvim-treesitter/nvim-treesitter-context",
|
"nvim-treesitter/nvim-treesitter-context",
|
||||||
},
|
},
|
||||||
config = function()
|
config = function()
|
||||||
@@ -24,11 +31,5 @@ return {
|
|||||||
"lua",
|
"lua",
|
||||||
"yaml",
|
"yaml",
|
||||||
})
|
})
|
||||||
require("nvim-ts-autotag").setup({
|
|
||||||
opts = {
|
|
||||||
enable_close = true,
|
|
||||||
enable_rename = true,
|
|
||||||
},
|
|
||||||
})
|
|
||||||
end,
|
end,
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -8,14 +8,11 @@ return {
|
|||||||
"nvim-telescope/telescope.nvim",
|
"nvim-telescope/telescope.nvim",
|
||||||
{
|
{
|
||||||
"folke/edgy.nvim",
|
"folke/edgy.nvim",
|
||||||
|
|
||||||
event = "VeryLazy",
|
event = "VeryLazy",
|
||||||
|
|
||||||
init = function()
|
init = function()
|
||||||
vim.opt.laststatus = 3
|
vim.opt.laststatus = 3
|
||||||
vim.opt.splitkeep = "screen" -- or "topline" or "screen"
|
vim.opt.splitkeep = "screen" -- or "topline" or "screen"
|
||||||
end,
|
end,
|
||||||
|
|
||||||
opts = {
|
opts = {
|
||||||
exit_when_last = false,
|
exit_when_last = false,
|
||||||
animate = {
|
animate = {
|
||||||
|
|||||||
@@ -1,4 +1,5 @@
|
|||||||
return {
|
return {
|
||||||
|
-- tree-like outline sidebar
|
||||||
"hedyhli/outline.nvim",
|
"hedyhli/outline.nvim",
|
||||||
keys = {
|
keys = {
|
||||||
{
|
{
|
||||||
@@ -7,14 +8,12 @@ return {
|
|||||||
desc = "CTags: toggle",
|
desc = "CTags: toggle",
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
config = function()
|
opts = {
|
||||||
require("outline").setup({
|
outline_window = {
|
||||||
outline_window = {
|
width = 25,
|
||||||
width = 25,
|
},
|
||||||
},
|
symbols = {
|
||||||
symbols = {
|
icon_source = "lspkind",
|
||||||
icon_source = "lspkind",
|
},
|
||||||
},
|
},
|
||||||
})
|
|
||||||
end,
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -7,10 +7,7 @@ return {
|
|||||||
"hrsh7th/nvim-cmp",
|
"hrsh7th/nvim-cmp",
|
||||||
"nvim-telescope/telescope.nvim",
|
"nvim-telescope/telescope.nvim",
|
||||||
},
|
},
|
||||||
config = function()
|
opts = {
|
||||||
require("papis").setup({
|
enable_keymaps = false,
|
||||||
-- Your configuration goes here
|
},
|
||||||
enable_keymaps = false,
|
|
||||||
})
|
|
||||||
end,
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -14,22 +14,22 @@ return {
|
|||||||
desc = "Telescope: find projects",
|
desc = "Telescope: find projects",
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
config = function()
|
opts = {
|
||||||
require("projections").setup({
|
workspaces = {
|
||||||
workspaces = { -- Default workspaces to search for
|
{ "~/code/main", { ".git" } },
|
||||||
{ "~/code/main", { ".git" } },
|
{ "~/code/uni", { ".git" } },
|
||||||
{ "~/code/uni", { ".git" } },
|
},
|
||||||
},
|
store_hooks = {
|
||||||
store_hooks = {
|
pre = function()
|
||||||
pre = function()
|
local ok, api = pcall(require, "nvim-tree.api")
|
||||||
-- nvim-tree
|
if ok then
|
||||||
local nvim_tree_present, api = pcall(require, "nvim-tree.api")
|
api.tree.close()
|
||||||
if nvim_tree_present then
|
end
|
||||||
api.tree.close()
|
end,
|
||||||
end
|
},
|
||||||
end,
|
},
|
||||||
},
|
config = function(_, opts)
|
||||||
})
|
require("projections").setup(opts)
|
||||||
require("telescope").load_extension("projections")
|
require("telescope").load_extension("projections")
|
||||||
end,
|
end,
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,24 +1,22 @@
|
|||||||
return {
|
return {
|
||||||
-- improve spelling check for coding to feature camelcase, etc
|
-- improve spelling check for coding to feature camelcase, etc
|
||||||
{
|
"kamykn/spelunker.vim",
|
||||||
"kamykn/spelunker.vim",
|
dependencies = { "kamykn/popup-menu.nvim" },
|
||||||
dependencies = { "kamykn/popup-menu.nvim" },
|
keys = {
|
||||||
keys = {
|
{
|
||||||
{
|
"<F10>t",
|
||||||
"<F10>t",
|
"<cmd>call spelunker#toggle()<CR>",
|
||||||
"<cmd>call spelunker#toggle()<CR>",
|
desc = "Spelunker: toggle spell check",
|
||||||
desc = "Spelunker: toggle spell check",
|
},
|
||||||
},
|
{
|
||||||
{
|
"<F10>s",
|
||||||
"<F10>s",
|
"z=",
|
||||||
"z=",
|
desc = "Spell: display suggestions",
|
||||||
desc = "Spell: display suggestions",
|
|
||||||
},
|
|
||||||
},
|
},
|
||||||
config = function()
|
|
||||||
-- vim.o.nospell = true
|
|
||||||
vim.g.enable_spelunker_vim = 0
|
|
||||||
vim.g.spelunker_disable_acronym_checking = 1
|
|
||||||
end,
|
|
||||||
},
|
},
|
||||||
|
config = function()
|
||||||
|
-- vim.o.nospell = true
|
||||||
|
vim.g.enable_spelunker_vim = 0
|
||||||
|
vim.g.spelunker_disable_acronym_checking = 1
|
||||||
|
end,
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -3,9 +3,7 @@ return {
|
|||||||
"tiyn/tccs.nvim",
|
"tiyn/tccs.nvim",
|
||||||
lazy = false,
|
lazy = false,
|
||||||
priority = 1000,
|
priority = 1000,
|
||||||
config = function()
|
opts = {
|
||||||
require("tccs").setup({
|
require("tccs").load(),
|
||||||
require("tccs").load(),
|
},
|
||||||
})
|
|
||||||
end,
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -3,11 +3,12 @@ return {
|
|||||||
"mcauley-penney/tidy.nvim",
|
"mcauley-penney/tidy.nvim",
|
||||||
branch = "main",
|
branch = "main",
|
||||||
ft = { "markdown", "tex" },
|
ft = { "markdown", "tex" },
|
||||||
config = function()
|
opts = {
|
||||||
|
filetype_exclude = { "diff" },
|
||||||
|
},
|
||||||
|
config = function(_, opts)
|
||||||
local tidy = require("tidy")
|
local tidy = require("tidy")
|
||||||
tidy.setup({
|
tidy.setup(opts)
|
||||||
filetype_exclude = { "diff" },
|
|
||||||
})
|
|
||||||
tidy.opts.enabled_on_save = false
|
tidy.opts.enabled_on_save = false
|
||||||
vim.api.nvim_create_autocmd("BufLeave", {
|
vim.api.nvim_create_autocmd("BufLeave", {
|
||||||
pattern = { "*.md", "*.tex" },
|
pattern = { "*.md", "*.tex" },
|
||||||
|
|||||||
@@ -3,11 +3,14 @@ return {
|
|||||||
"rachartier/tiny-inline-diagnostic.nvim",
|
"rachartier/tiny-inline-diagnostic.nvim",
|
||||||
event = "VeryLazy",
|
event = "VeryLazy",
|
||||||
priority = 1000,
|
priority = 1000,
|
||||||
config = function()
|
opts = {
|
||||||
require("tiny-inline-diagnostic").setup({
|
preset = "classic",
|
||||||
preset = "classic",
|
transparent_bg = true,
|
||||||
transparent_bg = true,
|
},
|
||||||
|
config = function(_, opts)
|
||||||
|
require("tiny-inline-diagnostic").setup(opts)
|
||||||
|
vim.diagnostic.config({
|
||||||
|
virtual_text = false,
|
||||||
})
|
})
|
||||||
vim.diagnostic.config({ virtual_text = false })
|
|
||||||
end,
|
end,
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -10,7 +10,5 @@ return {
|
|||||||
end,
|
end,
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
config = function()
|
opts = {},
|
||||||
require("treesj").setup()
|
|
||||||
end,
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -3,5 +3,5 @@ return {
|
|||||||
"preservim/vim-markdown",
|
"preservim/vim-markdown",
|
||||||
ft = { "markdown" },
|
ft = { "markdown" },
|
||||||
dependencies = { "godlygeek/tabular" },
|
dependencies = { "godlygeek/tabular" },
|
||||||
config = function() end,
|
config = function() end, -- needed this way by the plugin
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -2,7 +2,5 @@ return {
|
|||||||
-- highlighting for the viper verification language
|
-- highlighting for the viper verification language
|
||||||
"tiyn/viper.nvim",
|
"tiyn/viper.nvim",
|
||||||
event = { "BufReadPre *.vpr", "FileType viper" },
|
event = { "BufReadPre *.vpr", "FileType viper" },
|
||||||
config = function()
|
opts = {}
|
||||||
require("viper").setup()
|
|
||||||
end,
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -11,13 +11,14 @@ return {
|
|||||||
"romgrk/fzy-lua-native",
|
"romgrk/fzy-lua-native",
|
||||||
"nixprime/cpsm",
|
"nixprime/cpsm",
|
||||||
},
|
},
|
||||||
config = function()
|
opts = {
|
||||||
|
modes = { ":", "/", "?" },
|
||||||
|
accept_key = "<CR>",
|
||||||
|
reject_key = "<C-e>",
|
||||||
|
},
|
||||||
|
config = function(_, opts)
|
||||||
local wilder = require("wilder")
|
local wilder = require("wilder")
|
||||||
wilder.setup({
|
wilder.setup(opts)
|
||||||
modes = { ":", "/", "?" },
|
|
||||||
accept_key = "<CR>",
|
|
||||||
reject_key = "<C-e>",
|
|
||||||
})
|
|
||||||
wilder.set_option("pipeline", {
|
wilder.set_option("pipeline", {
|
||||||
wilder.branch(
|
wilder.branch(
|
||||||
wilder.python_file_finder_pipeline({
|
wilder.python_file_finder_pipeline({
|
||||||
|
|||||||
Reference in New Issue
Block a user