gitsigns, comment, cmake
This commit is contained in:
parent
cf9b76d0e0
commit
fbdad999cd
34
init.lua
34
init.lua
@ -9,40 +9,6 @@ require('my_plugins')
|
|||||||
require('my_keymappings')
|
require('my_keymappings')
|
||||||
require('my_options')
|
require('my_options')
|
||||||
require("my_autocommands")
|
require("my_autocommands")
|
||||||
-------------------- GITSIGNS ------------------------------
|
|
||||||
require('gitsigns').setup({
|
|
||||||
current_line_blame = true,
|
|
||||||
current_line_blame_opts = {
|
|
||||||
virt_text = true,
|
|
||||||
virt_text_pos = 'eol', -- 'eol' | 'overlay' | 'right_align'
|
|
||||||
delay = 1000,
|
|
||||||
ignore_whitespace = false,
|
|
||||||
},
|
|
||||||
})
|
|
||||||
-------------------- COMMENTED -----------------------------
|
|
||||||
require('Comment').setup({
|
|
||||||
toggler = {
|
|
||||||
---line-comment toggle
|
|
||||||
line = '<leader>cc',
|
|
||||||
},
|
|
||||||
opleader = {
|
|
||||||
---line-comment opfunc mapping
|
|
||||||
line = '<leader>c',
|
|
||||||
},
|
|
||||||
})
|
|
||||||
-------------------- CMAKE ---------------------------------
|
|
||||||
-- require('telescope').load_extension('cmake')
|
|
||||||
require('cmake').setup({
|
|
||||||
parameters_file = 'neovim.json', -- JSON file to store information about selected target, run arguments and build type.
|
|
||||||
build_dir = '{cwd}/build_nvim', -- Build directory. The expressions `{cwd}`, `{os}` and `{build_type}` will be expanded with the corresponding text values.
|
|
||||||
})
|
|
||||||
utils.map('n', '<F5>', ':CMake build<CR>:copen<CR>')
|
|
||||||
|
|
||||||
-- msbuild errorformat
|
|
||||||
opt.errorformat:append("\\ %#%f(%l\\\\\\,%c):\\ %m")
|
|
||||||
-- cl.exe errorformat
|
|
||||||
-- o.errorformat:append('\ %#%f(%l) : %#%t%[A-z]%# %m')
|
|
||||||
|
|
||||||
-------------------- LUALINE -------------------------------
|
-------------------- LUALINE -------------------------------
|
||||||
require('lualine').setup {
|
require('lualine').setup {
|
||||||
options = {theme = 'gruvbox-material'},
|
options = {theme = 'gruvbox-material'},
|
||||||
|
@ -46,13 +46,19 @@ return require('packer').startup(function()
|
|||||||
use {'ellisonleao/gruvbox.nvim'}
|
use {'ellisonleao/gruvbox.nvim'}
|
||||||
use {'lukas-reineke/indent-blankline.nvim'}
|
use {'lukas-reineke/indent-blankline.nvim'}
|
||||||
use {'nvim-lua/plenary.nvim'}
|
use {'nvim-lua/plenary.nvim'}
|
||||||
use {'lewis6991/gitsigns.nvim'}
|
use {
|
||||||
|
'lewis6991/gitsigns.nvim',
|
||||||
|
config = get_setup("gitsigns")
|
||||||
|
}
|
||||||
use {
|
use {
|
||||||
'kyazdani42/nvim-tree.lua',
|
'kyazdani42/nvim-tree.lua',
|
||||||
requires = 'kyazdani42/nvim-web-devicons',
|
requires = 'kyazdani42/nvim-web-devicons',
|
||||||
config = get_setup("nvim-tree")
|
config = get_setup("nvim-tree")
|
||||||
}
|
}
|
||||||
use{'numToStr/Comment.nvim'}
|
use{
|
||||||
|
'numToStr/Comment.nvim',
|
||||||
|
config = get_setup("comment")
|
||||||
|
}
|
||||||
use {
|
use {
|
||||||
'hrsh7th/nvim-cmp',
|
'hrsh7th/nvim-cmp',
|
||||||
requires = {
|
requires = {
|
||||||
@ -76,7 +82,8 @@ return require('packer').startup(function()
|
|||||||
use {'rafamadriz/friendly-snippets'}
|
use {'rafamadriz/friendly-snippets'}
|
||||||
use {'onsails/lspkind-nvim'}
|
use {'onsails/lspkind-nvim'}
|
||||||
use {'Shatur/neovim-cmake',
|
use {'Shatur/neovim-cmake',
|
||||||
requires = {'mfussenegger/nvim-dap'}
|
requires = {'mfussenegger/nvim-dap'},
|
||||||
|
config = get_setup("cmake")
|
||||||
}
|
}
|
||||||
use {
|
use {
|
||||||
'hoob3rt/lualine.nvim',
|
'hoob3rt/lualine.nvim',
|
||||||
|
14
lua/setup/cmake.lua
Normal file
14
lua/setup/cmake.lua
Normal file
@ -0,0 +1,14 @@
|
|||||||
|
local opt = vim.opt -- to set options
|
||||||
|
local utils = require('utils')
|
||||||
|
-- require('telescope').load_extension('cmake')
|
||||||
|
require('cmake').setup({
|
||||||
|
parameters_file = 'neovim.json', -- JSON file to store information about selected target, run arguments and build type.
|
||||||
|
build_dir = '{cwd}/build_nvim', -- Build directory. The expressions `{cwd}`, `{os}` and `{build_type}` will be expanded with the corresponding text values.
|
||||||
|
})
|
||||||
|
utils.map('n', '<F5>', ':CMake build<CR>:copen<CR>')
|
||||||
|
|
||||||
|
-- msbuild errorformat
|
||||||
|
opt.errorformat:append("\\ %#%f(%l\\\\\\,%c):\\ %m")
|
||||||
|
-- cl.exe errorformat
|
||||||
|
-- o.errorformat:append('\ %#%f(%l) : %#%t%[A-z]%# %m')
|
||||||
|
|
10
lua/setup/comment.lua
Normal file
10
lua/setup/comment.lua
Normal file
@ -0,0 +1,10 @@
|
|||||||
|
require('Comment').setup({
|
||||||
|
toggler = {
|
||||||
|
---line-comment toggle
|
||||||
|
line = '<leader>cc',
|
||||||
|
},
|
||||||
|
opleader = {
|
||||||
|
---line-comment opfunc mapping
|
||||||
|
line = '<leader>c',
|
||||||
|
},
|
||||||
|
})
|
9
lua/setup/gitsigns.lua
Normal file
9
lua/setup/gitsigns.lua
Normal file
@ -0,0 +1,9 @@
|
|||||||
|
require('gitsigns').setup({
|
||||||
|
current_line_blame = true,
|
||||||
|
current_line_blame_opts = {
|
||||||
|
virt_text = true,
|
||||||
|
virt_text_pos = 'eol', -- 'eol' | 'overlay' | 'right_align'
|
||||||
|
delay = 1000,
|
||||||
|
ignore_whitespace = false,
|
||||||
|
},
|
||||||
|
})
|
Loading…
x
Reference in New Issue
Block a user