nvim: add GuessIndent

nix-components
pegasust 2022-09-02 07:00:54 -07:00
parent c5bf754ec8
commit 019a04c5b2
1 changed files with 244 additions and 229 deletions

View File

@ -76,6 +76,7 @@ Plug('onsails/lspkind-nvim')
-- DevExp -- DevExp
Plug('windwp/nvim-autopairs') -- matches pairs like [] (),... Plug('windwp/nvim-autopairs') -- matches pairs like [] (),...
Plug('windwp/nvim-ts-autotag') -- matches tags <body>hello</body> Plug('windwp/nvim-ts-autotag') -- matches tags <body>hello</body>
Plug('NMAC427/guess-indent.nvim') -- guesses the indentation of an opened buffer
Plug('numToStr/Comment.nvim') -- "gc" to comment visual regions/lines Plug('numToStr/Comment.nvim') -- "gc" to comment visual regions/lines
Plug('lewis6991/gitsigns.nvim') -- add git info to sign columns Plug('lewis6991/gitsigns.nvim') -- add git info to sign columns
Plug('tpope/vim-fugitive') -- git commands in nvim Plug('tpope/vim-fugitive') -- git commands in nvim
@ -237,6 +238,20 @@ require('nvim-autopairs').setup {
check_ts = true, check_ts = true,
} }
require('guess-indent').setup {
auto_cmd = true, -- Set to false to disable automatic execution
filetype_exclude = { -- A list of filetypes for which the auto command gets disabled
"netrw",
"tutor",
},
buftype_exclude = { -- A list of buffer types for which the auto command gets disabled
"help",
"nofile",
"terminal",
"prompt",
},
}
-- harpoon: mark significant files & switch between them -- harpoon: mark significant files & switch between them
remap('n', '<leader>m', function() require('harpoon.mark').add_file() end) remap('n', '<leader>m', function() require('harpoon.mark').add_file() end)
local function harpoon_nav(key, nav_file_index, lead_keybind) local function harpoon_nav(key, nav_file_index, lead_keybind)