summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--.config/nvim/after/plugin/asyncomplete.lua (renamed from .config/nvim/lua/plugs-config/asyncomplete.lua)0
-rw-r--r--.config/nvim/after/plugin/floaterm.lua (renamed from .config/nvim/lua/plugs-config/floaterm.lua)0
-rw-r--r--.config/nvim/after/plugin/lualine.lua (renamed from .config/nvim/lua/plugs-config/lualine.lua)0
-rw-r--r--.config/nvim/after/plugin/nerd-commenter.lua (renamed from .config/nvim/lua/plugs-config/nerd-commenter.lua)0
-rw-r--r--.config/nvim/after/plugin/org.lua (renamed from .config/nvim/lua/plugs-config/org.lua)0
-rw-r--r--.config/nvim/after/plugin/quickscope.lua (renamed from .config/nvim/lua/plugs-config/quickscope.lua)0
-rw-r--r--.config/nvim/after/plugin/rainbow.lua (renamed from .config/nvim/lua/plugs-config/rainbow.lua)0
-rw-r--r--.config/nvim/after/plugin/signify.lua (renamed from .config/nvim/lua/plugs-config/signify.lua)0
-rw-r--r--.config/nvim/after/plugin/startify.lua (renamed from .config/nvim/lua/plugs-config/startify.lua)0
-rw-r--r--.config/nvim/after/plugin/treesitter.lua (renamed from .config/nvim/lua/plugs-config/treesitter.lua)0
-rw-r--r--.config/nvim/after/plugin/whichkey.lua (renamed from .config/nvim/lua/plugs-config/whichkey.lua)19
-rw-r--r--.config/nvim/init.lua22
-rw-r--r--.config/nvim/plug-config/vim-lsp.vim78
13 files changed, 66 insertions, 53 deletions
diff --git a/.config/nvim/lua/plugs-config/asyncomplete.lua b/.config/nvim/after/plugin/asyncomplete.lua
index da28c37..da28c37 100644
--- a/.config/nvim/lua/plugs-config/asyncomplete.lua
+++ b/.config/nvim/after/plugin/asyncomplete.lua
diff --git a/.config/nvim/lua/plugs-config/floaterm.lua b/.config/nvim/after/plugin/floaterm.lua
index 7f80d65..7f80d65 100644
--- a/.config/nvim/lua/plugs-config/floaterm.lua
+++ b/.config/nvim/after/plugin/floaterm.lua
diff --git a/.config/nvim/lua/plugs-config/lualine.lua b/.config/nvim/after/plugin/lualine.lua
index f3d2fe7..f3d2fe7 100644
--- a/.config/nvim/lua/plugs-config/lualine.lua
+++ b/.config/nvim/after/plugin/lualine.lua
diff --git a/.config/nvim/lua/plugs-config/nerd-commenter.lua b/.config/nvim/after/plugin/nerd-commenter.lua
index ddfadf2..ddfadf2 100644
--- a/.config/nvim/lua/plugs-config/nerd-commenter.lua
+++ b/.config/nvim/after/plugin/nerd-commenter.lua
diff --git a/.config/nvim/lua/plugs-config/org.lua b/.config/nvim/after/plugin/org.lua
index 662ad08..662ad08 100644
--- a/.config/nvim/lua/plugs-config/org.lua
+++ b/.config/nvim/after/plugin/org.lua
diff --git a/.config/nvim/lua/plugs-config/quickscope.lua b/.config/nvim/after/plugin/quickscope.lua
index 9fa10fe..9fa10fe 100644
--- a/.config/nvim/lua/plugs-config/quickscope.lua
+++ b/.config/nvim/after/plugin/quickscope.lua
diff --git a/.config/nvim/lua/plugs-config/rainbow.lua b/.config/nvim/after/plugin/rainbow.lua
index e0951b8..e0951b8 100644
--- a/.config/nvim/lua/plugs-config/rainbow.lua
+++ b/.config/nvim/after/plugin/rainbow.lua
diff --git a/.config/nvim/lua/plugs-config/signify.lua b/.config/nvim/after/plugin/signify.lua
index a0a0a1d..a0a0a1d 100644
--- a/.config/nvim/lua/plugs-config/signify.lua
+++ b/.config/nvim/after/plugin/signify.lua
diff --git a/.config/nvim/lua/plugs-config/startify.lua b/.config/nvim/after/plugin/startify.lua
index a5d3efc..a5d3efc 100644
--- a/.config/nvim/lua/plugs-config/startify.lua
+++ b/.config/nvim/after/plugin/startify.lua
diff --git a/.config/nvim/lua/plugs-config/treesitter.lua b/.config/nvim/after/plugin/treesitter.lua
index 62b960b..62b960b 100644
--- a/.config/nvim/lua/plugs-config/treesitter.lua
+++ b/.config/nvim/after/plugin/treesitter.lua
diff --git a/.config/nvim/lua/plugs-config/whichkey.lua b/.config/nvim/after/plugin/whichkey.lua
index 9529229..71274e1 100644
--- a/.config/nvim/lua/plugs-config/whichkey.lua
+++ b/.config/nvim/after/plugin/whichkey.lua
@@ -1,10 +1,11 @@
-local wk = require("which-key")
+local ts = require('telescope.builtin')
+local wk = require('which-key')
wk.register({
b = { ':Buffers<CR>', 'buffers', noremap = true, silent = true },
c = { name = '+nerd-commenter' },
d = { ':bd<CR>', 'close buffer', noremap = true, silent = false },
- e = { ':Files<CR>', 'files', noremap = true, silent = true },
+ e = { ':Telescope find_files<CR>', 'find files', noremap = true, silent = true },
G = { ':FloatermNew lazygit<CR>', 'lazygit', noremap = true, silent = true },
h = { ':Startify<CR>', 'startify', noremap = true, silent = true },
k = { ':w<CR>:bp<CR>:bd #<CR>', 'write and close buffer', noremap = true, silent = false },
@@ -17,7 +18,12 @@ wk.register({
r = { name = '+coc-rename' },
f = {
name = 'telescope',
- f = { ':Telescope find_files<CR>', 'find files', noremap = true, silent = true },
+ -- f = { ':Telescope find_files<CR>', 'find files', noremap = true, silent = true },
+ f = { ts.find_files, 'find files', noremap = true, silent = true },
+ g = { ts.git_files, 'git files', noremap = true, silent = true },
+ s = { function()
+ ts.grep_string({ search = vim.fn.input("Grep > ") })
+ end, 'grep string', noremap = true, silent = true },
},
g = {
name = 'grep',
@@ -25,6 +31,11 @@ wk.register({
g = { ':Grep<CR>', 'grep', noremap = true, silent = true },
r = { ':Rg<CR>', 'ripgrep', noremap = true, silent = true },
},
+ v = {
+ name = 'nvim',
+ v = { vim.cmd.Ex, 'explorer', noremap = true, silent = true },
+ u = { ':PlugUpgrade<CR>:PlugUpdate<CR>', 'upgrade', noremap = true, silent = true },
+ },
}, { prefix = '<leader>', })
wk.setup({
plugins = {
@@ -41,3 +52,5 @@ wk.setup({
triggers = { "<leader>" },
triggers_nowait = { "d" },
})
+
+vim.keymap.set('n', '<C-p>', ts.git_files)
diff --git a/.config/nvim/init.lua b/.config/nvim/init.lua
index b4eefd1..7746dbb 100644
--- a/.config/nvim/init.lua
+++ b/.config/nvim/init.lua
@@ -20,15 +20,15 @@ require('settings')
require('bindings')
require('sidebars')
require('langs')
-require('plugs-config/asyncomplete')
-require('plugs-config/floaterm')
-require('plugs-config/lualine')
-require('plugs-config/nerd-commenter')
-require('plugs-config/org')
-require('plugs-config/quickscope')
-require('plugs-config/rainbow')
-require('plugs-config/signify')
-require('plugs-config/startify')
-require('plugs-config/treesitter')
-require('plugs-config/whichkey')
+-- require('plugs-config/asyncomplete')
+-- require('plugs-config/floaterm')
+-- require('plugs-config/lualine')
+-- require('plugs-config/nerd-commenter')
+-- require('plugs-config/org')
+-- require('plugs-config/quickscope')
+-- require('plugs-config/rainbow')
+-- require('plugs-config/signify')
+-- require('plugs-config/startify')
+-- require('plugs-config/treesitter')
+-- require('plugs-config/whichkey')
vim.cmd('source ' .. confdir .. '/nvim/plug-config/vim-lsp.vim')
diff --git a/.config/nvim/plug-config/vim-lsp.vim b/.config/nvim/plug-config/vim-lsp.vim
index fb0d055..5e5ca16 100644
--- a/.config/nvim/plug-config/vim-lsp.vim
+++ b/.config/nvim/plug-config/vim-lsp.vim
@@ -1,39 +1,39 @@
-if executable('ccls')
- autocmd User lsp_setup call lsp#register_server({
- \ 'name': 'ccls',
- \ 'cmd': {server_info->['ccls']},
- \ 'root_uri': {server_info->lsp#utils#path_to_uri(lsp#utils#find_nearest_parent_file_directory(lsp#utils#get_buffer_path(), 'compile_commands.json'))},
- \ 'initialization_options': {
- \ 'highlight': { 'lsRanges' : v:true },
- \ },
- \ 'whitelist': ['c', 'cpp', 'objc', 'objcpp', 'cc'],
- \ })
- autocmd FileType c,cpp,objc,objcpp,cc setlocal omnifunc=lsp#complete
-endif
-
-highlight LspCxxHlSymStruct ctermfg=Yellow guifg=Yellow
-highlight LspCxxHlSymClass ctermfg=Yellow guifg=Yellow
-highlight LspCxxHlSymField ctermfg=Blue guifg=Blue
-highlight LspCxxHlSymParameter ctermfg=LightYellow guifg=LightYellow
-highlight LspCxxHlSymVariableStatic ctermfg=LightRed guifg=LightRed
-highlight LspErrorHighlight cterm=undercurl gui=undercurl ctermfg=DarkRed guifg=DarkRed
-highlight LspWarningHighlight cterm=underline gui=underline ctermfg=DarkRed guifg=DarkRed
-highlight LspInformationHighlight cterm=underline gui=underline ctermfg=Green guifg=Green
-highlight LspHintHighlight term=italic cterm=italic gui=italic ctermfg=Green guifg=Green
-
-augroup LspGo
- au!
- autocmd User lsp_setup call lsp#register_server({
- \ 'name': 'go-lang',
- \ 'cmd': {server_info->['gopls']},
- \ 'whitelist': ['go'],
- \ })
- autocmd FileType go setlocal omnifunc=lsp#complete
- "autocmd FileType go nmap <buffer> gd <plug>(lsp-definition)
- "autocmd FileType go nmap <buffer> ,n <plug>(lsp-next-error)
- "autocmd FileType go nmap <buffer> ,p <plug>(lsp-previous-error)
-augroup END
-
-let g:lsp_signs_priority = 10
-let g:lsp_textprop_enabled = 1
-let g:lsp_cxx_hl_use_text_props = 1
+" if executable('ccls')
+" autocmd User lsp_setup call lsp#register_server({
+" \ 'name': 'ccls',
+" \ 'cmd': {server_info->['ccls']},
+" \ 'root_uri': {server_info->lsp#utils#path_to_uri(lsp#utils#find_nearest_parent_file_directory(lsp#utils#get_buffer_path(), 'compile_commands.json'))},
+" \ 'initialization_options': {
+" \ 'highlight': { 'lsRanges' : v:true },
+" \ },
+" \ 'whitelist': ['c', 'cpp', 'objc', 'objcpp', 'cc'],
+" \ })
+" autocmd FileType c,cpp,objc,objcpp,cc setlocal omnifunc=lsp#complete
+" endif
+"
+" highlight LspCxxHlSymStruct ctermfg=Yellow guifg=Yellow
+" highlight LspCxxHlSymClass ctermfg=Yellow guifg=Yellow
+" highlight LspCxxHlSymField ctermfg=Blue guifg=Blue
+" highlight LspCxxHlSymParameter ctermfg=LightYellow guifg=LightYellow
+" highlight LspCxxHlSymVariableStatic ctermfg=LightRed guifg=LightRed
+" highlight LspErrorHighlight cterm=undercurl gui=undercurl ctermfg=DarkRed guifg=DarkRed
+" highlight LspWarningHighlight cterm=underline gui=underline ctermfg=DarkRed guifg=DarkRed
+" highlight LspInformationHighlight cterm=underline gui=underline ctermfg=Green guifg=Green
+" highlight LspHintHighlight term=italic cterm=italic gui=italic ctermfg=Green guifg=Green
+"
+" augroup LspGo
+" au!
+" autocmd User lsp_setup call lsp#register_server({
+" \ 'name': 'go-lang',
+" \ 'cmd': {server_info->['gopls']},
+" \ 'whitelist': ['go'],
+" \ })
+" autocmd FileType go setlocal omnifunc=lsp#complete
+" "autocmd FileType go nmap <buffer> gd <plug>(lsp-definition)
+" "autocmd FileType go nmap <buffer> ,n <plug>(lsp-next-error)
+" "autocmd FileType go nmap <buffer> ,p <plug>(lsp-previous-error)
+" augroup END
+"
+" let g:lsp_signs_priority = 10
+" let g:lsp_textprop_enabled = 1
+" let g:lsp_cxx_hl_use_text_props = 1