vimgrep: add vim-ripgrep to use ripgreg
* Set ripgrep highlighting to true. * Reset leader key to default (`\`). * Harmonize all let statements without spaces before and after the `=`. Co-Authored-by: Igor Milhit <igor@milhit.ch>server
parent
2461aca883
commit
f448e33fe4
18
init.vim
18
init.vim
|
@ -33,10 +33,10 @@ Plug 'neomake/neomake' " Python linting
|
||||||
" Imports sorting
|
" Imports sorting
|
||||||
Plug 'stsewd/isort.nvim', { 'do': ':UpdateRemotePlugins' }
|
Plug 'stsewd/isort.nvim', { 'do': ':UpdateRemotePlugins' }
|
||||||
Plug 'vitalk/vim-simple-todo'
|
Plug 'vitalk/vim-simple-todo'
|
||||||
|
" Search
|
||||||
|
Plug 'jremmen/vim-ripgrep' " Use ripgrep
|
||||||
call plug#end()
|
call plug#end()
|
||||||
|
|
||||||
let mapleader = "<"
|
|
||||||
|
|
||||||
" Filetype detection
|
" Filetype detection
|
||||||
filetype plugin on
|
filetype plugin on
|
||||||
|
|
||||||
|
@ -46,7 +46,7 @@ if has("autocmd")
|
||||||
endif
|
endif
|
||||||
|
|
||||||
" add some tags for html indentations
|
" add some tags for html indentations
|
||||||
:let g:html_indent_inctags = "html,body,head,tbody"
|
let g:html_indent_inctags="html,body,head,tbody"
|
||||||
|
|
||||||
set smartindent
|
set smartindent
|
||||||
set tabstop=4
|
set tabstop=4
|
||||||
|
@ -59,15 +59,16 @@ set showmatch " Show matching brackets.
|
||||||
set ignorecase " Do case insensitive matching
|
set ignorecase " Do case insensitive matching
|
||||||
set smartcase " Do smart case matching
|
set smartcase " Do smart case matching
|
||||||
set hlsearch " Highlight search
|
set hlsearch " Highlight search
|
||||||
|
let g:rg_highlight='true' " Activate ripgrep Highlighting
|
||||||
nnoremap <silent> <C-l> :nohlsearch<CR><C-l> " set C-l to :nohlsearch
|
nnoremap <silent> <C-l> :nohlsearch<CR><C-l> " set C-l to :nohlsearch
|
||||||
set autowrite " Automatically save before commands like :next and :make
|
set autowrite " Automatically save before commands like :next and :make
|
||||||
set hidden " Hide buffers when they are abandoned
|
set hidden " Hide buffers when they are abandoned
|
||||||
set mouse=a " Enable mouse usage (all modes)
|
set mouse=a " Enable mouse usage (all modes)
|
||||||
set linebreak " Line wrap
|
set linebreak " Line wrap
|
||||||
set tw=79 " Lines longer than 79 chars will be wrapped
|
set tw=79 " Lines longer than 79 chars will be wrapped
|
||||||
autocmd FileType gitcommit set textwidth=72
|
autocmd FileType gitcommit set textwidth=72 " Wrap lines longer than 72 chars for git messages
|
||||||
set colorcolumn=+1 " Colors the tw+1 column
|
set colorcolumn=+1 " Colors the tw+1 column
|
||||||
autocmd FileType gitcommit set colorcolumn+=51
|
autocmd FileType gitcommit set colorcolumn+=51 " Add a colored column at 51 chars for git message titles
|
||||||
set number " Line numbering
|
set number " Line numbering
|
||||||
au TermOpen * setlocal listchars= nonumber norelativenumber
|
au TermOpen * setlocal listchars= nonumber norelativenumber
|
||||||
set cursorline
|
set cursorline
|
||||||
|
@ -111,10 +112,9 @@ set clipboard+=unnamedplus
|
||||||
let g:airline_powerline_fonts=1
|
let g:airline_powerline_fonts=1
|
||||||
let g:airline#extensions#wordcount#filetypes='pandoc\|text\|' "Add support when pandoc is activated
|
let g:airline#extensions#wordcount#filetypes='pandoc\|text\|' "Add support when pandoc is activated
|
||||||
let g:airline_theme='nord'
|
let g:airline_theme='nord'
|
||||||
" let g:airline_section_x = '%{PencilMode()}'
|
|
||||||
|
|
||||||
" vim-table-mode
|
" vim-table-mode
|
||||||
:let g:table_mode_corner='|'
|
let g:table_mode_corner='|'
|
||||||
|
|
||||||
" NERDTree
|
" NERDTree
|
||||||
autocmd StdinReadPre * let s:std_in=1
|
autocmd StdinReadPre * let s:std_in=1
|
||||||
|
@ -134,9 +134,13 @@ let g:ctrlp_use_caching = 1
|
||||||
let g:ctrlp_clear_cache_on_exit=0
|
let g:ctrlp_clear_cache_on_exit=0
|
||||||
|
|
||||||
" Pandoc
|
" Pandoc
|
||||||
|
" Autoformatting with hardwrap
|
||||||
let g:pandoc#formatting#mode="hA"
|
let g:pandoc#formatting#mode="hA"
|
||||||
|
" ctrl+s switch to softwrap
|
||||||
nnoremap <C-s> :call pandoc#formatting#UseSoftWraps()
|
nnoremap <C-s> :call pandoc#formatting#UseSoftWraps()
|
||||||
|
" ctrl+h switch to hardwrap
|
||||||
nnoremap <C-h> :call pandoc#formatting#UseHardWraps()
|
nnoremap <C-h> :call pandoc#formatting#UseHardWraps()
|
||||||
|
" ctrl+t toggle autoformat (mainly to deactivate it when necessary)
|
||||||
nnoremap <C-t> :call pandoc#formatting#ToggleAutoformat()
|
nnoremap <C-t> :call pandoc#formatting#ToggleAutoformat()
|
||||||
|
|
||||||
" autocompletion
|
" autocompletion
|
||||||
|
|
Loading…
Reference in New Issue