nvim/lua/custom/plugins.lua

200 lines
7.2 KiB
Lua
Raw Permalink Normal View History

2024-01-08 19:53:30 +01:00
local plugins = {
{
"neovim/nvim-lspconfig",
config = function ()
require "plugins.configs.lspconfig"
require "custom.configs.lspconfig"
end,
},
{
"williamboman/mason.nvim",
opts = {
ensure_installed = {
"gopls",
"pyright",
}
}
},
{
"nvimtools/none-ls.nvim",
ft = "go",
opts = function ()
return require "custom.configs.none-ls"
end,
},
2024-01-09 10:49:02 +01:00
-- Go plugins
2024-01-12 19:15:02 +01:00
{
"ray-x/go.nvim",
config = function()
require("go").setup()
require("core.utils").load_mappings("gopher")
end,
event = {"CmdlineEnter"},
ft = {"go", 'gomod'},
build = ':lua require("go.install").update_all_sync()' -- if you need to install/update all binaries
},
2024-01-09 10:49:02 +01:00
-- Markdown plugins
2024-09-16 16:52:29 +02:00
-- {
-- 'ixru/nvim-markdown',
-- ft = "markdown",
-- },
2024-01-09 10:49:02 +01:00
{
"iamcco/markdown-preview.nvim",
cmd = { "MarkdownPreviewToggle", "MarkdownPreview", "MarkdownPreviewStop" },
ft = { "markdown" },
build = function() vim.fn["mkdp#util#install"]() end,
2024-05-16 10:52:15 +02:00
},
2024-09-16 16:52:29 +02:00
{
'MeanderingProgrammer/render-markdown.nvim',
opts = {},
dependencies = { 'nvim-treesitter/nvim-treesitter', 'echasnovski/mini.nvim', 'nvim-treesitter/nvim-web-devicons' }, -- if you use the mini.nvim suite
config = function ()
require('render-markdown').enable()
require('render-markdown').setup({
file_types = { 'markdown', 'quatro' },
heading = {
-- Turn on / off heading icon & background rendering
enabled = true,
-- Turn on / off any sign column related rendering
sign = true,
-- Determines how icons fill the available space:
-- inline: underlying '#'s are concealed resulting in a left aligned icon
-- overlay: result is left padded with spaces to hide any additional '#'
position = 'overlay',
-- Replaces '#+' of 'atx_h._marker'
-- The number of '#' in the heading determines the 'level'
-- The 'level' is used to index into the array using a cycle
icons = { '󰲡 ', '󰲣 ', '󰲥 ', '󰲧 ', '󰲩 ', '󰲫 ' },
-- Added to the sign column if enabled
-- The 'level' is used to index into the array using a cycle
signs = { '󰫎 ' },
-- Width of the heading background:
-- block: width of the heading text
-- full: full width of the window
-- Can also be an array of the above values in which case the 'level' is used
-- to index into the array using a clamp
width = 'full',
-- Amount of padding to add to the left of headings
left_pad = 0,
-- Amount of padding to add to the right of headings when width is 'block'
right_pad = 0,
-- Minimum width to use for headings when width is 'block'
min_width = 0,
-- Determins if a border is added above and below headings
border = false,
-- Highlight the start of the border using the foreground highlight
border_prefix = false,
-- Used above heading for border
above = '',
-- Used below heading for border
below = '',
-- The 'level' is used to index into the array using a clamp
-- Highlight for the heading icon and extends through the entire line
backgrounds = {
'RenderMarkdownH1Bg',
'RenderMarkdownH2Bg',
'RenderMarkdownH3Bg',
'RenderMarkdownH4Bg',
'RenderMarkdownH5Bg',
'RenderMarkdownH6Bg',
},
-- The 'level' is used to index into the array using a clamp
-- Highlight for the heading and sign icons
foregrounds = {
'RenderMarkdownH1',
'RenderMarkdownH2',
'RenderMarkdownH3',
'RenderMarkdownH4',
'RenderMarkdownH5',
'RenderMarkdownH6',
},
},
code = {
-- Turn on / off code block & inline code rendering
enabled = true,
-- Turn on / off any sign column related rendering
sign = true,
-- Determines how code blocks & inline code are rendered:
-- none: disables all rendering
-- normal: adds highlight group to code blocks & inline code, adds padding to code blocks
-- language: adds language icon to sign column if enabled and icon + name above code blocks
-- full: normal + language
style = 'full',
-- Determines where language icon is rendered:
-- right: right side of code block
-- left: left side of code block
position = 'left',
-- Amount of padding to add around the language
language_pad = 0,
-- An array of language names for which background highlighting will be disabled
-- Likely because that language has background highlights itself
disable_background = { 'diff' },
-- Width of the code block background:
-- block: width of the code block
-- full: full width of the window
width = 'full',
-- Amount of padding to add to the left of code blocks
left_pad = 0,
-- Amount of padding to add to the right of code blocks when width is 'block'
right_pad = 0,
-- Minimum width to use for code blocks when width is 'block'
min_width = 0,
-- Determins how the top / bottom of code block are rendered:
-- thick: use the same highlight as the code body
-- thin: when lines are empty overlay the above & below icons
border = 'thin',
-- Used above code blocks for thin border
above = '',
-- Used below code blocks for thin border
below = '',
-- Highlight for code blocks
highlight = 'RenderMarkdownCode',
-- Highlight for inline code
highlight_inline = 'RenderMarkdownCodeInline',
},
bullet = {
-- Turn on / off list bullet rendering
enabled = true,
-- Replaces '-'|'+'|'*' of 'list_item'
-- How deeply nested the list is determines the 'level'
-- The 'level' is used to index into the array using a cycle
-- If the item is a 'checkbox' a conceal is used to hide the bullet instead
icons = { '', '', '', '' },
-- Padding to add to the left of bullet point
left_pad = 0,
-- Padding to add to the right of bullet point
right_pad = 0,
-- Highlight for the bullet icon
highlight = 'RenderMarkdownBullet',
},
})
end
},
2024-05-16 10:52:15 +02:00
-- Utility plugins
{
'liuchengxu/vista.vim',
lazy = false,
},
-- Git
{
"kdheepak/lazygit.nvim",
cmd = {
"LazyGit",
"LazyGitConfig",
"LazyGitCurrentFile",
"LazyGitFilter",
"LazyGitFilterCurrentFile",
},
-- optional for floating window border decoration
dependencies = {
"nvim-lua/plenary.nvim",
},
-- setting the keybinding for LazyGit with 'keys' is recommended in
-- order to load the plugin when the command is run for the first time
keys = {
{ "<leader>lg", "<cmd>LazyGit<cr>", desc = "LazyGit" }
}
2024-01-09 10:49:02 +01:00
}
2024-01-08 19:53:30 +01:00
}
return plugins