mirror of
https://codeberg.org/leana8959/.files.git
synced 2025-12-06 14:49:14 +00:00
add(nvim): nvim config rewrite (wip)
This commit is contained in:
parent
649ad5de0f
commit
f5a5fc368e
6 changed files with 163 additions and 513 deletions
74
.config/nvim/lua/core/plugins.lua
Normal file
74
.config/nvim/lua/core/plugins.lua
Normal file
|
|
@ -0,0 +1,74 @@
|
|||
require('gitsigns').setup {
|
||||
signs = {
|
||||
add = { text = '+' },
|
||||
change = { text = '~' },
|
||||
delete = { text = '-' },
|
||||
topdelete = { text = '-' },
|
||||
changedelete = { text = '~' },
|
||||
untracked = { text = '·' },
|
||||
},
|
||||
signcolumn = true, -- Toggle with `:Gitsigns toggle_signs`
|
||||
numhl = false, -- Toggle with `:Gitsigns toggle_numhl`
|
||||
linehl = false, -- Toggle with `:Gitsigns toggle_linehl`
|
||||
word_diff = false, -- Toggle with `:Gitsigns toggle_word_diff`
|
||||
watch_gitdir = {
|
||||
interval = 2500,
|
||||
follow_files = true
|
||||
},
|
||||
attach_to_untracked = true,
|
||||
current_line_blame = true, -- Toggle with `:Gitsigns toggle_current_line_blame`
|
||||
current_line_blame_opts = {
|
||||
virt_text = true,
|
||||
virt_text_pos = 'eol', -- 'eol' | 'overlay' | 'right_align'
|
||||
delay = 500,
|
||||
ignore_whitespace = false,
|
||||
},
|
||||
current_line_blame_formatter = '<author>, <author_time:%Y-%m-%d> - <summary>',
|
||||
sign_priority = 6,
|
||||
update_debounce = 100,
|
||||
status_formatter = nil, -- Use default
|
||||
max_file_length = 40000, -- Disable if file is longer than this (in lines)
|
||||
preview_config = {
|
||||
-- Options passed to nvim_open_win
|
||||
border = 'single',
|
||||
style = 'minimal',
|
||||
relative = 'cursor',
|
||||
row = 0,
|
||||
col = 1
|
||||
},
|
||||
yadm = {
|
||||
enable = false
|
||||
},
|
||||
}
|
||||
|
||||
require'nvim-treesitter.configs'.setup {
|
||||
-- A list of parser names, or "all" (the four listed parsers should always be installed)
|
||||
ensure_installed = { "c", "cpp", "lua", "vim", "help", "rust", "scala", "python"},
|
||||
|
||||
-- Install parsers synchronously (only applied to `ensure_installed`)
|
||||
sync_install = false,
|
||||
|
||||
-- Automatically install missing parsers when entering buffer
|
||||
-- Recommendation: set to false if you don't have `tree-sitter` CLI installed locally
|
||||
auto_install = true,
|
||||
|
||||
highlight = {
|
||||
enable = true,
|
||||
-- Setting this to true will run `:h syntax` and tree-sitter at the same time.
|
||||
-- Set this to `true` if you depend on 'syntax' being enabled (like for indentation).
|
||||
-- Using this option may slow down your editor, and you may see some duplicate highlights.
|
||||
-- Instead of true it can also be a list of languages
|
||||
additional_vim_regex_highlighting = false,
|
||||
},
|
||||
|
||||
incremental_selection = {
|
||||
enable = true,
|
||||
keymaps = {
|
||||
-- set to `false` to disable one of the mappings
|
||||
init_selection = "false",
|
||||
scope_incremental = "false",
|
||||
node_incremental = "<A-Up>",
|
||||
node_decremental = "<A-Down>",
|
||||
},
|
||||
},
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue