102 lines
2.9 KiB
VimL
102 lines
2.9 KiB
VimL
" Use the default config as base because lazy lazy
|
|
unlet! skip_defaults_vim
|
|
source $VIMRUNTIME/defaults.vim
|
|
|
|
""
|
|
" General stuffies
|
|
""
|
|
if has('termguicolors') " if terminal supports truecolor enable it
|
|
set termguicolors
|
|
endif
|
|
|
|
filetype plugin on
|
|
set number " blub- plain numbering on the left, nothin fancy
|
|
set splitbelow splitright " spawn splits where I expect them to be..
|
|
syntax enable
|
|
set title
|
|
set autoread " automagically reload files if edited elsewhere
|
|
|
|
" Indenting settings :o
|
|
set tabstop=4
|
|
set expandtab
|
|
set shiftwidth=4
|
|
set autoindent
|
|
set smartindent
|
|
set confirm " ask for comfirmation to save a file before quitting
|
|
|
|
""
|
|
" Loading plugins woaaahh (VimPlug)
|
|
""
|
|
|
|
|
|
call plug#begin()
|
|
Plug 'mhinz/vim-signify' " show uncommited changes
|
|
Plug 'ntpeters/vim-better-whitespace' " Whitespace Highlighting
|
|
Plug 'preservim/nerdcommenter' " I am lazy with commenting
|
|
Plug 'lambdalisue/fern.vim' " File manager, file tree sidebar, fancy thing
|
|
Plug 'junegunn/fzf.vim' " fuzzy find files, very handy
|
|
Plug 'jiangmiao/auto-pairs' " I like my brackets and quotes to double down
|
|
Plug 'vimwiki/vimwiki' " it's, like, for taking notes
|
|
Plug 'wincent/terminus' " makes vim in terminal nicer! btw this makes the cursor change shape :3
|
|
Plug 'voldikss/vim-floaterm'
|
|
Plug 'moll/vim-bbye' " retain windows when deleting buffers
|
|
|
|
let g:polyglot_disabled = ['autoindent'] " disable autoindent polyglot's autoindent cause bleh
|
|
Plug 'https://github.com/sheerun/vim-polyglot' " Many many little language gremlins in a trenchcoat
|
|
|
|
" Fancy status bar
|
|
Plug 'vim-airline/vim-airline'
|
|
|
|
" Theme
|
|
Plug 'ghifarit53/tokyonight-vim'
|
|
|
|
let g:airline#extensions#tabline#enabled = 1
|
|
let g:airline_powerline_fonts = 0
|
|
set noshowmode " Airline already shows the mode
|
|
call plug#end()
|
|
|
|
" Set the theme! it be really comfi
|
|
colorscheme tokyonight
|
|
|
|
" spawn fzf on the bottom of the editor instead of a popup in the middle
|
|
let g:fzf_layout = { 'down': '40%' }
|
|
|
|
""
|
|
" Key binds stuffies
|
|
""
|
|
|
|
" leader key
|
|
let mapleader=" "
|
|
|
|
" Reload this very config file
|
|
nmap <leader>cr :source ~/.vim/vimrc<CR>
|
|
" Open this very config file
|
|
nmap <leader>ce :e ~/.vim/vimrc<CR>
|
|
|
|
" Fern sidebar
|
|
nmap <leader>ff :Fern . -drawer<CR>
|
|
nmap <leader>ft :Fern . -drawer -toggle<CR>
|
|
|
|
" Buffer stuff
|
|
nmap <leader>bl :buffers<CR>
|
|
nmap <leader>bb :Buffers<CR>
|
|
nmap <leader>bd :Bdelete<CR>
|
|
nmap <leader>bn :bNext<CR>
|
|
nmap <leader>bp :bPrevious<CR>
|
|
|
|
" Toggle spell checking
|
|
map <leader>tse :setlocal spell! spelllang=en<CR>
|
|
map <leader>tsr :setlocal spell! spelllang=ro<CR>
|
|
|
|
" Manouver files
|
|
nmap <leader>fw :w<CR>
|
|
nmap <leader>. :cd<space>
|
|
nmap <leader><leader> :Files<CR>
|
|
|
|
" Open lazygit
|
|
nmap <leader>gg :FloatermNew lazygit<CR>
|
|
|
|
" Exit vim entirely
|
|
nmap <leader>qq :qa<CR>
|
|
" Exit vim forcefuly!!
|
|
nmap <leader>qQ :qa!<CR>
|