about summary refs log tree commit diff stats
path: root/.config/nvim/init.vim
blob: 58f279849075ef83795b73e4b17d89a2b5acf74e (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
set nocompatible

" inteligent indentation
filetype indent plugin on
set tabstop=4 softtabstop=4 shiftwidth=4 expandtab smartindent
set showmatch ignorecase smartcase
set noswapfile

set clipboard=unnamedplus

set undofile " persist undo

syntax on
set termguicolors

set number relativenumber numberwidth=2 cursorline
set conceallevel=3

set background=dark
let g:sonokai_style = 'shusia'
let g:sonokai_better_performance = 1
let g:sonokai_transparent_background = 1
colo sonokai

"" bindings
" leader mapping
nnoremap <SPACE> <Nop>
let mapleader=" "
let localleader=" " 

" easy splits
nnoremap <leader>h <C-w>h
nnoremap <leader>j <C-w>j
nnoremap <leader>k <C-w>k
nnoremap <leader>l <C-w>l
nnoremap <leader>L :vs<CR>
nnoremap <leader>J :sp<CR>
nnoremap <silent> <Esc><Esc> :nohlsearch<CR>
set splitright splitbelow

" easy write
nmap <leader>w :w!<CR>
nmap <leader>W :w!<CR>
nmap <leader>q :wq!<CR>

" easy term-mode
tnoremap <C-\> <C-\><C-n>

" emmet
let g:user_emmet_mode='n' " only on normal mode, thx
let g:user_emmet_install_global = 0
autocmd FileType html,css EmmetInstall

let g:user_emmet_leader_key=','