dotfiles-linux-bash/config/nvim/init.vim

55 lines
1.4 KiB
VimL
Raw Normal View History

syntax enable
2020-05-06 14:23:54 +00:00
let mapleader = " "
call plug#begin('~/.vim/plugged')
Plug 'ervandew/supertab'
Plug 'dracula/vim', { 'as': 'dracula' }
Plug 'preservim/nerdtree'
Plug 'junegunn/fzf', { 'dir': '~/.fzf', 'do': './install --all' }
Plug 'junegunn/fzf.vim'
Plug 'mhinz/vim-startify'
Plug 'jeetsukumaran/vim-buffergator'
Plug 'ap/vim-buftabline'
Plug 'airblade/vim-gitgutter'
2020-05-06 14:23:54 +00:00
Plug 'majutsushi/tagbar'
Plug 'vim-airline/vim-airline'
2021-10-29 21:25:22 +00:00
" Plug 'ctrlpvim/ctrlp.vim' " Replaced with telescope
2020-05-06 14:23:54 +00:00
Plug 'enricobacis/vim-airline-clock'
2021-10-29 21:25:22 +00:00
Plug 'nvim-lua/plenary.nvim'
Plug 'nvim-telescope/telescope.nvim'
2020-05-06 14:23:54 +00:00
call plug#end()
map <C-o> :NERDTreeToggle<CR>
2020-05-06 14:23:54 +00:00
set tabstop=2
set shell=/bin/bash
set shiftwidth=2
set expandtab
set hidden
set background=dark
colorscheme dracula
2020-05-06 14:23:54 +00:00
" Relative numbers and when not in buiffer set absolute numbers
set number relativenumber
augroup numbertoggle
autocmd!
autocmd BufEnter,FocusGained,InsertLeave * set relativenumber
autocmd BufLeave,FocusLost,InsertEnter * set norelativenumber
augroup END
" Colors
nnoremap <Leader>/ :Ag<CR>
nnoremap <C-J> :bnext<CR>
nnoremap <C-K> :bprev<CR>
nmap <leader>bq :bp <BAR> bd #<CR>
"Clock
let g:airline#extensions#clock#format = '%I:%M:%S %X'
2021-10-29 21:25:22 +00:00
" Find files using Telescope command-line sugar.
nnoremap <leader>ff <cmd>Telescope find_files<cr>
nnoremap <leader>fg <cmd>Telescope live_grep<cr>
nnoremap <leader>fb <cmd>Telescope buffers<cr>
nnoremap <leader>fh <cmd>Telescope help_tags<cr>