vim: stylistic tweaks
This commit is contained in:
parent
a00e28b031
commit
3e9376bf82
5 changed files with 40 additions and 31 deletions
|
@ -1,6 +1,8 @@
|
|||
return {
|
||||
'norcalli/nvim-colorizer.lua',
|
||||
|
||||
cond = vim.opt.termguicolors:get(),
|
||||
|
||||
config = function()
|
||||
require('colorizer').setup({'*'}, { mode = 'foreground' })
|
||||
end,
|
||||
|
|
|
@ -1,5 +1,6 @@
|
|||
return {
|
||||
'tpope/vim-fugitive',
|
||||
|
||||
config = function()
|
||||
vim.keymap.set('n', '<leader>gs', '<cmd>tab Git<cr>')
|
||||
vim.keymap.set('n', '<leader>gb', '<cmd>Git blame<cr>')
|
||||
|
|
|
@ -1,10 +1,12 @@
|
|||
return {
|
||||
'lukas-reineke/indent-blankline.nvim',
|
||||
|
||||
config = function()
|
||||
require('indent_blankline').setup {
|
||||
enabled = false,
|
||||
}
|
||||
opts = {
|
||||
enabled = false,
|
||||
},
|
||||
|
||||
config = function(_, opts)
|
||||
require('indent_blankline').setup(opts)
|
||||
|
||||
-- show/hide indent guides
|
||||
vim.keymap.set('n', '<leader>si', '<cmd>IndentBlanklineToggle<cr>')
|
||||
|
|
|
@ -14,33 +14,35 @@ end
|
|||
return {
|
||||
'kyazdani42/nvim-tree.lua',
|
||||
|
||||
config = function()
|
||||
require('nvim-tree').setup {
|
||||
disable_netrw = true, -- replace netrw with nvim-tree
|
||||
hijack_cursor = true, -- keep the cursor on begin of the filename
|
||||
sync_root_with_cwd = true, -- watch for `DirChanged` and refresh the tree
|
||||
on_attach = on_attach,
|
||||
opts = {
|
||||
disable_netrw = true, -- replace netrw with nvim-tree
|
||||
hijack_cursor = true, -- keep the cursor on begin of the filename
|
||||
sync_root_with_cwd = true, -- watch for `DirChanged` and refresh the tree
|
||||
on_attach = on_attach,
|
||||
|
||||
git = {
|
||||
ignore = false, -- don't hide files from .gitignore
|
||||
},
|
||||
git = {
|
||||
ignore = false, -- don't hide files from .gitignore
|
||||
},
|
||||
|
||||
view = {
|
||||
adaptive_size = true, -- resize the window based on the longest line
|
||||
width = 35, -- a little wider than the default 30
|
||||
},
|
||||
view = {
|
||||
adaptive_size = true, -- resize the window based on the longest line
|
||||
width = 35, -- a little wider than the default 30
|
||||
},
|
||||
|
||||
filters = {
|
||||
dotfiles = false, -- show files starting with a .
|
||||
custom = { '^\\.git' }, -- don't show .git directory
|
||||
},
|
||||
filters = {
|
||||
dotfiles = false, -- show files starting with a .
|
||||
custom = { '^\\.git' }, -- don't show .git directory
|
||||
},
|
||||
|
||||
renderer = {
|
||||
add_trailing = true, -- add trailing / to folders
|
||||
group_empty = true, -- folders that contain only one folder are grouped
|
||||
highlight_git = true, -- enable highlight based on git attributes
|
||||
},
|
||||
}
|
||||
renderer = {
|
||||
add_trailing = true, -- add trailing / to folders
|
||||
group_empty = true, -- folders that contain only one folder are grouped
|
||||
highlight_git = true, -- enable highlight based on git attributes
|
||||
},
|
||||
},
|
||||
|
||||
config = function(_, opts)
|
||||
require('nvim-tree').setup(opts)
|
||||
|
||||
vim.keymap.set('n', '<leader>nn', '<cmd>NvimTreeOpen<cr>')
|
||||
vim.keymap.set('n', '<leader>nf', '<cmd>NvimTreeFindFile<cr>')
|
||||
|
|
|
@ -1,10 +1,12 @@
|
|||
return {
|
||||
'lukas-reineke/virt-column.nvim',
|
||||
|
||||
config = function()
|
||||
require('virt-column').setup {
|
||||
char = '│',
|
||||
}
|
||||
opts = {
|
||||
char = '│',
|
||||
},
|
||||
|
||||
config = function(_, opts)
|
||||
require('virt-column').setup(opts)
|
||||
|
||||
local toggle_virtual_column = function()
|
||||
if vim.o.colorcolumn == '' then
|
||||
|
|
Loading…
Add table
Reference in a new issue