lua grep theming
This commit is contained in:
parent
2e0dabc7f8
commit
86669142bf
2 changed files with 36 additions and 5 deletions
|
|
@ -111,3 +111,30 @@ require('lspkind').init({
|
|||
Struct = 'struct',
|
||||
},
|
||||
})
|
||||
|
||||
require('telescope').setup {
|
||||
|
||||
}
|
||||
|
||||
local builtin = require'telescope.builtin'
|
||||
|
||||
local dropdown = require'telescope.themes'.get_dropdown({
|
||||
--previewer = false,
|
||||
--prompt_title = "",
|
||||
--results_height = 16,
|
||||
--width = 0.6,
|
||||
--borderchars = {
|
||||
--{"─", "│", "─", "│", "╭", "╮", "╯", "╰"},
|
||||
--prompt = {"─", "│", " ", "│", "╭", "╮", "│", "│"},
|
||||
--results = {"─", "│", "─", "│", "├", "┤", "╯", "╰"},
|
||||
--preview = {"─", "│", "─", "│", "╭", "╮", "╯", "╰"}
|
||||
--},
|
||||
--winblend = 10
|
||||
})
|
||||
|
||||
git_grep_word = function(conf)
|
||||
local opt = dropdown
|
||||
opt.cwd = vim.fn.systemlist("git rev-parse --show-toplevel")[1]
|
||||
for k,v in pairs(conf) do opt[k] = v end
|
||||
builtin.grep_string(opt)
|
||||
end
|
||||
|
|
|
|||
14
.vimrc
14
.vimrc
|
|
@ -134,8 +134,8 @@ Plug 'sjbach/lusty'
|
|||
Plug 'mhinz/vim-signify'
|
||||
Plug 'vim-airline/vim-airline'
|
||||
Plug 'vim-airline/vim-airline-themes'
|
||||
Plug 'junegunn/fzf', { 'do': { -> fzf#install() } }
|
||||
Plug 'junegunn/fzf.vim'
|
||||
"Plug 'junegunn/fzf', { 'do': { -> fzf#install() } }
|
||||
"Plug 'junegunn/fzf.vim'
|
||||
Plug 'airblade/vim-rooter'
|
||||
"Plug 'bling/vim-bufferline'
|
||||
Plug 'majutsushi/tagbar'
|
||||
|
|
@ -902,10 +902,14 @@ call denite#custom#var('grep', {
|
|||
\ })
|
||||
"nnoremap <silent> <Leader>g :<C-u>Denite -buffer-name=search-buffer grep<CR>
|
||||
"nnoremap <silent> <Leader>aa :<C-u>RipGrep!<CR>
|
||||
nnoremap <silent> <Leader>aa :<C-u>RgRoot!<CR>
|
||||
nnoremap <silent> <Leader>aw :<C-u>RgRoot! <C-r><C-w><CR>
|
||||
"nnoremap <silent> <Leader>aa :<C-u>RgRoot!<CR>
|
||||
"nnoremap <silent> <Leader>aw :<C-u>RgRoot! <C-r><C-w><CR>
|
||||
"nnoremap <C-l> :<C-u>Files! `git rev-parse --show-toplevel`<CR>
|
||||
nnoremap <C-k> :<C-u>GFiles<CR>
|
||||
"nnoremap <C-k> :<C-u>GFiles<CR>
|
||||
nnoremap <C-k> <cmd>lua require('telescope.builtin').git_files()<cr>
|
||||
nnoremap <silent> <Leader>ag <cmd>lua git_grep_word{ word_match = "-w", only_sort_text = true, search = ''}<cr>
|
||||
nnoremap <silent> <Leader>aw <cmd>lua git_grep_word{ word_match = "-w", only_sort_text = true }<cr>
|
||||
|
||||
" For C++ -- A is a great plugin which allows you to jump from the c file to the
|
||||
" header and vice-versa. Mneumonic here is headerheader.
|
||||
nnoremap <Leader>hh :A<CR>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue