" ----- Tabs ----- " nnoremap :tabnew nnoremap :tabclose noremap :tabnext inoremap :tabnext cnoremap :tabnext noremap ::tabprevious inoremap :tabprevious cnoremap :tabprevious " unmap command! W command! Q :wq! " NvimTRee noremap n :NvimTreeToggle " -- Comments -- " vmap C ToggleCommaround vmap c ToggleCommaround " Code Block Scope nnoremap es :IBLToggle " -- Todo Comments search -- " nnoremap cf :TodoTelescope " Delete entire word with CTRL-BS or CTRL-H noremap! noremap! inoremap db " -- Coc -- " nnoremap ce :CocEnable nnoremap cd :CocDisable " -- CSS -- " au FileType css inoremap { {}A au FileType css map * I/*A*/ " Don't leave block indentation vmap < >gv " Compilation map m :!make " List all URLS in a file nnoremap u :Urlview " FZF " nnoremap f :FZF " Code Search (silver searcher) " nnoremap cs :Ag " function! ToggleAg() " if exists("t:fzf_window") " " If the fzf window exists, close it " call fzf#vim#cancel() " else " " Otherwise, open the fzf window with a prompt for input " call fzf#vim#ag('', fzf#vim#with_preview()) " endif " endfunction " " Code Search (silver searcher) " " nnoremap cs :call ToggleAg() " " Enable Spell Check map s :setlocal spell! spelllang=en_us map p :!opout % " Undo Tree nnoremap :UndotreeToggle " NERD TREE nnoremap :NERDTreeToggle " Telescope " Find files using Telescope command-line sugar. nnoremap ff Telescope find_files nnoremap fg Telescope live_grep nnoremap fb Telescope buffers nnoremap fh Telescope help_tags " Using Lua functions nnoremap ff lua require('telescope.builtin').find_files() nnoremap fg lua require('telescope.builtin').live_grep() nnoremap fb lua require('telescope.builtin').buffers() nnoremap fh lua require('telescope.builtin').help_tags()