2022-12-31 17:43:31 +01:00
|
|
|
return {
|
2023-01-01 19:36:00 +01:00
|
|
|
'folke/which-key.nvim',
|
2023-04-08 23:47:10 +02:00
|
|
|
'nvim-lua/plenary.nvim',
|
2023-06-20 19:01:48 +02:00
|
|
|
-- 'mfussenegger/nvim-jdtls',
|
|
|
|
-- 'simrat39/rust-tools.nvim',
|
|
|
|
{ 'rush-rs/tree-sitter-asm', ft = 'asm' },
|
|
|
|
{ 'jghauser/mkdir.nvim', lazy = false },
|
2023-04-15 15:47:38 +02:00
|
|
|
{
|
2023-06-19 11:36:51 +02:00
|
|
|
url = 'https://git.filnar.com/fiplox/neogruber.git',
|
|
|
|
-- dir = '~/dev/neogruber.nvim/',
|
2023-04-15 15:47:38 +02:00
|
|
|
lazy = false,
|
|
|
|
-- event = 'VeryLazy'
|
|
|
|
},
|
2022-12-31 17:43:31 +01:00
|
|
|
{
|
2023-06-21 22:18:24 +02:00
|
|
|
'folke/flash.nvim',
|
|
|
|
-- event = 'VeryLazy',
|
|
|
|
---@type Flash.Config
|
|
|
|
opts = {},
|
|
|
|
keys = {
|
|
|
|
{
|
|
|
|
's',
|
|
|
|
mode = { 'n', 'x', 'o' },
|
|
|
|
function()
|
|
|
|
-- default options: exact mode, multi window, all directions, with a backdrop
|
|
|
|
require('flash').jump()
|
|
|
|
end,
|
|
|
|
},
|
|
|
|
{
|
|
|
|
'S',
|
|
|
|
mode = { 'o', 'x' },
|
|
|
|
function()
|
|
|
|
require('flash').treesitter()
|
|
|
|
end,
|
|
|
|
},
|
|
|
|
},
|
2022-12-31 17:43:31 +01:00
|
|
|
},
|
2023-04-15 15:47:38 +02:00
|
|
|
{
|
|
|
|
'numToStr/Comment.nvim',
|
|
|
|
-- event = 'VeryLazy',
|
|
|
|
keys = { 'gcc', { 'gc', mode = 'v' }, { 'gb', mode = 'v' } },
|
|
|
|
opts = {
|
|
|
|
-- -LHS of operator-pending mappings in NORMAL and VISUAL mode
|
|
|
|
opleader = {
|
|
|
|
---Line-comment keymap
|
|
|
|
line = 'gc',
|
|
|
|
---Block-comment keymap
|
|
|
|
block = 'gb',
|
|
|
|
},
|
|
|
|
---LHS of extra mappings
|
|
|
|
extra = {
|
|
|
|
---Add comment on the line above
|
|
|
|
above = 'gcO',
|
|
|
|
---Add comment on the line below
|
|
|
|
below = 'gco',
|
|
|
|
---Add comment at the end of line
|
|
|
|
eol = 'gca',
|
|
|
|
},
|
|
|
|
---Enable keybindings
|
|
|
|
---NOTE: If given `false` then the plugin won't create any mappings
|
|
|
|
mappings = {
|
|
|
|
---Operator-pending mapping; `gcc` `gbc` `gc[count]{motion}` `gb[count]{motion}`
|
|
|
|
basic = true,
|
|
|
|
---Extra mapping; `gco`, `gcO`, `gcA`
|
|
|
|
extra = true,
|
|
|
|
---Extended mapping; `g>` `g<` `g>[count]{motion}` `g<[count]{motion}`
|
|
|
|
extended = false,
|
|
|
|
},
|
|
|
|
pre_hook = function(ctx)
|
|
|
|
-- Only calculate commentstring for tsx filetypes
|
|
|
|
if vim.bo.filetype == 'typescriptreact' then
|
|
|
|
local U = require 'Comment.utils'
|
|
|
|
|
|
|
|
-- Determine whether to use linewise or blockwise commentstring
|
|
|
|
local type = ctx.ctype == U.ctype.linewise and '__default' or '__multiline'
|
|
|
|
|
|
|
|
-- Determine the location where to calculate commentstring from
|
|
|
|
local location = nil
|
|
|
|
if ctx.ctype == U.ctype.blockwise then
|
|
|
|
location = require('ts_context_commentstring.utils').get_cursor_location()
|
|
|
|
elseif ctx.cmotion == U.cmotion.v or ctx.cmotion == U.cmotion.V then
|
2023-06-20 19:01:48 +02:00
|
|
|
location = require('ts_context_commentstring.utils')
|
|
|
|
.get_visual_start_location()
|
2023-04-15 15:47:38 +02:00
|
|
|
end
|
|
|
|
|
|
|
|
return require('ts_context_commentstring.internal').calculate_commentstring {
|
|
|
|
key = type,
|
|
|
|
location = location,
|
|
|
|
}
|
|
|
|
end
|
|
|
|
end,
|
|
|
|
},
|
|
|
|
},
|
|
|
|
{
|
|
|
|
'NvChad/nvim-colorizer.lua',
|
|
|
|
-- event = 'BufReadPre',
|
|
|
|
cmd = 'ColorizerToggle',
|
|
|
|
opts = {
|
|
|
|
filetypes = { '*', '!lazy' },
|
|
|
|
buftype = { '*', '!prompt', '!nofile' },
|
|
|
|
user_default_options = {
|
|
|
|
RGB = true, -- #RGB hex codes
|
|
|
|
RRGGBB = true, -- #RRGGBB hex codes #ffffff
|
|
|
|
names = false, -- "Name" codes like Blue
|
|
|
|
RRGGBBAA = true, -- #RRGGBBAA hex codes
|
|
|
|
AARRGGBB = false, -- 0xAARRGGBB hex codes
|
|
|
|
rgb_fn = true, -- CSS rgb() and rgba() functions
|
|
|
|
hsl_fn = true, -- CSS hsl() and hsla() functions
|
|
|
|
css = false, -- Enable all CSS features: rgb_fn, hsl_fn, names, RGB, RRGGBB
|
|
|
|
css_fn = true, -- Enable all CSS *functions*: rgb_fn, hsl_fn
|
|
|
|
-- Available modes: foreground, background
|
|
|
|
-- Available modes for `mode`: foreground, background, virtualtext
|
|
|
|
-- mode = "background", -- Set the display mode.
|
|
|
|
-- virtualtext = "■",
|
|
|
|
},
|
|
|
|
},
|
|
|
|
},
|
|
|
|
{
|
|
|
|
'williamboman/mason.nvim',
|
|
|
|
cmd = 'Mason',
|
|
|
|
opts = {
|
|
|
|
settings = {
|
|
|
|
ui = {
|
|
|
|
border = 'rounded',
|
|
|
|
icons = {
|
|
|
|
package_installed = '◍',
|
|
|
|
package_pending = '◍',
|
|
|
|
package_uninstalled = '◍',
|
2023-04-09 18:27:34 +02:00
|
|
|
},
|
2023-04-09 00:44:17 +02:00
|
|
|
},
|
2023-04-15 15:47:38 +02:00
|
|
|
-- log_level = vim.log.levels.INFO,
|
|
|
|
max_concurrent_installers = 4,
|
|
|
|
},
|
|
|
|
},
|
|
|
|
},
|
|
|
|
{
|
|
|
|
'TimUntersberger/neogit',
|
|
|
|
dependencies = 'sindrets/diffview.nvim',
|
|
|
|
cmd = 'Neogit',
|
|
|
|
opts = {
|
|
|
|
disable_signs = false,
|
|
|
|
disable_hint = false,
|
|
|
|
disable_context_highlighting = false,
|
|
|
|
disable_commit_confirmation = true,
|
|
|
|
-- Neogit refreshes its internal state after specific events, which can be expensive depending on the repository size.
|
|
|
|
-- Disabling `auto_refresh` will make it so you have to manually refresh the status after you open it.
|
|
|
|
auto_refresh = true,
|
|
|
|
disable_builtin_notifications = false,
|
|
|
|
use_magit_keybindings = false,
|
|
|
|
-- Change the default way of opening neogit
|
|
|
|
kind = 'replace',
|
|
|
|
-- The time after which an output console is shown for slow running commands
|
|
|
|
console_timeout = 2000,
|
|
|
|
-- Automatically show console if a command takes more than console_timeout milliseconds
|
|
|
|
auto_show_console = true,
|
|
|
|
-- Change the default way of opening the commit popup
|
|
|
|
commit_popup = {
|
|
|
|
kind = 'split',
|
|
|
|
},
|
|
|
|
-- Change the default way of opening popups
|
|
|
|
popup = {
|
|
|
|
kind = 'split',
|
|
|
|
},
|
|
|
|
status = {
|
|
|
|
recent_commit_count = 50,
|
|
|
|
},
|
|
|
|
-- customize displayed signs
|
|
|
|
signs = {
|
|
|
|
-- { CLOSED, OPENED }
|
|
|
|
section = { '>', 'v' },
|
|
|
|
item = { '>', 'v' },
|
|
|
|
hunk = { '', '' },
|
|
|
|
},
|
|
|
|
integrations = {
|
|
|
|
-- Neogit only provides inline diffs. If you want a more traditional way to look at diffs, you can use `sindrets/diffview.nvim`.
|
|
|
|
-- The diffview integration enables the diff popup, which is a wrapper around `sindrets/diffview.nvim`.
|
|
|
|
--
|
|
|
|
-- Requires you to have `sindrets/diffview.nvim` installed.
|
|
|
|
diffview = true,
|
|
|
|
},
|
|
|
|
-- Setting any section to `false` will make the section not render at all
|
|
|
|
sections = {
|
|
|
|
untracked = {
|
|
|
|
folded = false,
|
|
|
|
},
|
|
|
|
unstaged = {
|
|
|
|
folded = false,
|
|
|
|
},
|
|
|
|
staged = {
|
|
|
|
folded = false,
|
|
|
|
},
|
|
|
|
stashes = {
|
|
|
|
folded = true,
|
|
|
|
},
|
|
|
|
unpulled = {
|
|
|
|
folded = true,
|
|
|
|
},
|
|
|
|
unmerged = {
|
|
|
|
folded = false,
|
|
|
|
},
|
|
|
|
recent = {
|
|
|
|
folded = true,
|
|
|
|
},
|
|
|
|
},
|
|
|
|
-- override/add mappings
|
|
|
|
mappings = {
|
|
|
|
-- modify status buffer mappings
|
|
|
|
status = {
|
|
|
|
-- Adds a mapping with "B" as key that does the "BranchPopup" command
|
|
|
|
['B'] = 'BranchPopup',
|
|
|
|
-- Removes the default mapping of "s"
|
|
|
|
-- ['s'] = '',
|
|
|
|
},
|
|
|
|
},
|
|
|
|
},
|
|
|
|
},
|
|
|
|
{
|
|
|
|
'stevearc/oil.nvim',
|
2023-06-21 22:18:24 +02:00
|
|
|
-- lazy = false,
|
|
|
|
event = 'Syntax',
|
2023-04-15 15:47:38 +02:00
|
|
|
opts = {
|
|
|
|
-- Buffer-local options to use for oil buffers
|
|
|
|
buf_options = {
|
|
|
|
buflisted = false,
|
|
|
|
},
|
|
|
|
-- Window-local options to use for oil buffers
|
|
|
|
win_options = {
|
|
|
|
concealcursor = 'nvic',
|
|
|
|
},
|
|
|
|
keymaps = {
|
|
|
|
['g?'] = 'actions.show_help',
|
|
|
|
['<CR>'] = 'actions.select',
|
|
|
|
['<C-s>'] = 'actions.select_vsplit',
|
|
|
|
['<C-h>'] = 'actions.select_split',
|
|
|
|
['<C-p>'] = 'actions.preview',
|
|
|
|
['<TAB>'] = 'actions.preview',
|
|
|
|
['<C-c>'] = 'actions.close',
|
|
|
|
['q'] = 'actions.close',
|
|
|
|
['<C-l>'] = 'actions.refresh',
|
|
|
|
['-'] = 'actions.parent',
|
|
|
|
['l'] = 'actions.parent',
|
|
|
|
['_'] = 'actions.open_cwd',
|
|
|
|
['`'] = 'actions.cd',
|
|
|
|
['~'] = 'actions.tcd',
|
|
|
|
['g.'] = 'actions.toggle_hidden',
|
|
|
|
},
|
|
|
|
},
|
|
|
|
},
|
|
|
|
{
|
|
|
|
'akinsho/toggleterm.nvim',
|
|
|
|
cmd = 'ToggleTerm',
|
|
|
|
opts = {
|
|
|
|
-- size can be a number or function which is passed the current terminal
|
|
|
|
-- size = function(term)
|
|
|
|
-- if term.direction == 'horizontal' then
|
|
|
|
-- return 15
|
|
|
|
-- elseif term.direction == 'vertical' then
|
|
|
|
-- return vim.o.columns * 0.4
|
|
|
|
-- end
|
|
|
|
-- end,
|
|
|
|
shade_filetypes = { 'none', 'fzf' },
|
|
|
|
-- open_mapping = [[<home>]],
|
|
|
|
hide_numbers = true, -- hide the number column in toggleterm buffers
|
|
|
|
shade_terminals = true,
|
|
|
|
shading_factor = '2', -- the degree by which to darken to terminal colour, default: 1 for dark backgrounds, 3 for light
|
|
|
|
start_in_insert = true,
|
|
|
|
insert_mappings = true, -- whether or not the open mapping applies in insert mode
|
|
|
|
persist_size = true,
|
|
|
|
-- direction = 'horizontal', -- 'vertical' | 'horizontal' | 'window' | 'float',
|
|
|
|
direction = 'float', -- 'vertical' | 'horizontal' | 'window' | 'float',
|
|
|
|
close_on_exit = true, -- close the terminal window when the process exits
|
|
|
|
shell = vim.o.shell, -- change the default shell
|
|
|
|
-- This field is only relevant if direction is set to 'float'
|
|
|
|
float_opts = {
|
|
|
|
-- The border key is *almost* the same as 'nvim_win_open'
|
|
|
|
-- see :h nvim_win_open for details on borders however
|
|
|
|
-- the 'curved' border is a custom border type
|
|
|
|
-- not natively supported but implemented in this plugin.
|
|
|
|
border = 'curved', -- | 'double' | 'shadow' | 'curved' --| ... other options supported by win open
|
|
|
|
-- width = 100,
|
|
|
|
-- height = 30,
|
|
|
|
-- winblend = 20,
|
|
|
|
-- highlights = {
|
|
|
|
-- border = 'Normal',
|
|
|
|
-- background = 'Normal',
|
|
|
|
-- },
|
|
|
|
},
|
|
|
|
},
|
|
|
|
},
|
2023-06-20 19:01:48 +02:00
|
|
|
{
|
2023-04-15 15:47:38 +02:00
|
|
|
'nvim-treesitter/nvim-treesitter',
|
|
|
|
-- lazy = false,
|
|
|
|
-- dependencies = { 'nvim-treesitter/playground' },
|
|
|
|
-- dependencies = 'windwp/nvim-ts-autotag',
|
|
|
|
config = function()
|
2023-06-19 11:33:42 +02:00
|
|
|
-- require('nvim-treesitter.parsers').get_parser_configs().asm = {
|
|
|
|
-- install_info = {
|
|
|
|
-- url = 'https://github.com/rush-rs/tree-sitter-asm.git',
|
|
|
|
-- files = { 'src/parser.c' },
|
|
|
|
-- branch = 'main',
|
|
|
|
-- },
|
|
|
|
-- }
|
2023-04-15 15:47:38 +02:00
|
|
|
local configs = require 'nvim-treesitter.configs'
|
|
|
|
|
|
|
|
configs.setup {
|
|
|
|
ignore_install = { 'haskell' },
|
|
|
|
highlight = {
|
|
|
|
enable = true, -- false will disable the whole extension
|
|
|
|
disable = { 'html' },
|
|
|
|
},
|
|
|
|
-- context_commentstring = { enable = true, config = { css = '// %s' } },
|
|
|
|
-- indent = {enable = true, disable = {"python", "html", "javascript"}},
|
|
|
|
-- TODO seems to be broken
|
2023-06-19 11:33:42 +02:00
|
|
|
indent = { enable = false, disable = { 'python', 'css' } },
|
2023-04-15 15:47:38 +02:00
|
|
|
-- autotag = { enable = true },
|
2023-04-09 00:44:17 +02:00
|
|
|
}
|
|
|
|
end,
|
|
|
|
},
|
2023-04-15 15:47:38 +02:00
|
|
|
{
|
|
|
|
'j-morano/buffer_manager.nvim',
|
|
|
|
opts = {
|
|
|
|
-- line_keys = '', -- deactivate line keybindings
|
|
|
|
select_menu_item_commands = {
|
|
|
|
edit = {
|
|
|
|
key = '<CR>',
|
|
|
|
command = 'edit',
|
|
|
|
},
|
|
|
|
v = {
|
|
|
|
key = '<C-v>',
|
|
|
|
command = 'vsplit',
|
|
|
|
},
|
|
|
|
h = {
|
|
|
|
key = '<C-h>',
|
|
|
|
command = 'split',
|
|
|
|
},
|
|
|
|
},
|
|
|
|
width = 0.6,
|
|
|
|
},
|
|
|
|
},
|
2022-12-31 17:43:31 +01:00
|
|
|
}
|