mirror of
https://github.com/frebib/dotfiles.git
synced 2024-06-14 12:57:23 +00:00
Compare commits
3 Commits
0ff266f257
...
d1c4112ee3
Author | SHA1 | Date | |
---|---|---|---|
d1c4112ee3 | |||
8c8048ebcb | |||
019a3f9c18 |
@ -366,28 +366,6 @@ mouse:
|
|||||||
# If this is `true`, the cursor is temporarily hidden when typing.
|
# If this is `true`, the cursor is temporarily hidden when typing.
|
||||||
hide_when_typing: false
|
hide_when_typing: false
|
||||||
|
|
||||||
url:
|
|
||||||
# URL launcher
|
|
||||||
#
|
|
||||||
# This program is executed when clicking on a text which is recognized as a URL.
|
|
||||||
# The URL is always added to the command as the last parameter.
|
|
||||||
#
|
|
||||||
# When set to `None`, URL launching will be disabled completely.
|
|
||||||
#
|
|
||||||
# Default:
|
|
||||||
# - (macOS) open
|
|
||||||
# - (Linux/BSD) xdg-open
|
|
||||||
# - (Windows) explorer
|
|
||||||
launcher:
|
|
||||||
program: xdg-open
|
|
||||||
args: []
|
|
||||||
|
|
||||||
# URL modifiers
|
|
||||||
#
|
|
||||||
# These are the modifiers that need to be held down for opening URLs when clicking
|
|
||||||
# on them. The available modifiers are documented in the key binding section.
|
|
||||||
#modifiers: None
|
|
||||||
|
|
||||||
# Mouse bindings
|
# Mouse bindings
|
||||||
#
|
#
|
||||||
# Mouse bindings are specified as a list of objects, much like the key
|
# Mouse bindings are specified as a list of objects, much like the key
|
||||||
|
98
vim/vimrc
98
vim/vimrc
@ -39,10 +39,17 @@ set updatetime=500 " reduce delay from 4s default
|
|||||||
|
|
||||||
let mapleader="\<space>"
|
let mapleader="\<space>"
|
||||||
|
|
||||||
|
" ALE config
|
||||||
|
let g:ale_completion_enabled = 1
|
||||||
|
let g:ale_open_list = 1
|
||||||
|
augroup CloseLoclistWindowGroup
|
||||||
|
autocmd!
|
||||||
|
autocmd QuitPre * if empty(&buftype) | lclose | endif
|
||||||
|
augroup END
|
||||||
|
|
||||||
" Autosave settings
|
" Autosave settings
|
||||||
function! SaveIfExist()
|
function! SaveIfExist()
|
||||||
if @% != "" && filereadable(@%) && !&readonly && &modified
|
if @% != "" && filereadable(@%) && !&readonly && &modified
|
||||||
SyntasticCheck
|
|
||||||
write
|
write
|
||||||
endif
|
endif
|
||||||
endfunction
|
endfunction
|
||||||
@ -66,11 +73,8 @@ set list
|
|||||||
set listchars=eol:$,space:·,tab:>-,trail:◦,extends:▶,precedes:◀
|
set listchars=eol:$,space:·,tab:>-,trail:◦,extends:▶,precedes:◀
|
||||||
highlight SpecialKey ctermfg=8
|
highlight SpecialKey ctermfg=8
|
||||||
|
|
||||||
if exists('+colorcolumn')
|
set cc=+1
|
||||||
highlight ColorColumn ctermbg=8
|
highlight ColorColumn ctermbg=8
|
||||||
autocmd filetype c,h,cpp,hpp set colorcolumn=81
|
|
||||||
autocmd filetype c,h,cpp,hpp match ErrorMsg '\%>80v.\+'
|
|
||||||
endif
|
|
||||||
|
|
||||||
" Highlight line and column of cursor
|
" Highlight line and column of cursor
|
||||||
set cul cuc
|
set cul cuc
|
||||||
@ -85,8 +89,6 @@ endif
|
|||||||
|
|
||||||
call plug#begin('$XDG_CONFIG_HOME/vim/plug')
|
call plug#begin('$XDG_CONFIG_HOME/vim/plug')
|
||||||
|
|
||||||
Plug 'Valloric/YouCompleteMe'
|
|
||||||
Plug 'scrooloose/syntastic'
|
|
||||||
Plug 'scrooloose/nerdtree', { 'on': 'NERTreeToggle' }
|
Plug 'scrooloose/nerdtree', { 'on': 'NERTreeToggle' }
|
||||||
Plug 'tpope/vim-sensible'
|
Plug 'tpope/vim-sensible'
|
||||||
Plug 'tpope/vim-fugitive'
|
Plug 'tpope/vim-fugitive'
|
||||||
@ -103,6 +105,13 @@ Plug 'vim-airline/vim-airline-themes'
|
|||||||
Plug 'lervag/vimtex'
|
Plug 'lervag/vimtex'
|
||||||
Plug 'JamshedVesuna/vim-markdown-preview'
|
Plug 'JamshedVesuna/vim-markdown-preview'
|
||||||
Plug 'junegunn/fzf.vim'
|
Plug 'junegunn/fzf.vim'
|
||||||
|
|
||||||
|
" Completion and linting
|
||||||
|
Plug 'dense-analysis/ale'
|
||||||
|
Plug 'Shougo/deoplete.nvim'
|
||||||
|
Plug 'roxma/nvim-yarp'
|
||||||
|
Plug 'roxma/vim-hug-neovim-rpc'
|
||||||
|
|
||||||
Plug 'fatih/vim-go', { 'do': ':GoUpdateBinaries' }
|
Plug 'fatih/vim-go', { 'do': ':GoUpdateBinaries' }
|
||||||
|
|
||||||
" Syntax Highlighting
|
" Syntax Highlighting
|
||||||
@ -111,22 +120,39 @@ Plug 'PotatoesMaster/i3-vim-syntax'
|
|||||||
Plug 'puppetlabs/puppet-syntax-vim'
|
Plug 'puppetlabs/puppet-syntax-vim'
|
||||||
Plug 'saltstack/salt-vim'
|
Plug 'saltstack/salt-vim'
|
||||||
Plug 'arrufat/vala.vim'
|
Plug 'arrufat/vala.vim'
|
||||||
|
Plug 'Glench/Vim-Jinja2-Syntax'
|
||||||
|
Plug 'pearofducks/ansible-vim'
|
||||||
|
Plug 'jvirtanen/vim-hcl'
|
||||||
|
Plug 'hashivim/vim-terraform'
|
||||||
|
|
||||||
call plug#end()
|
call plug#end()
|
||||||
|
|
||||||
" Change to dvorak-mapped keys
|
" Change to dvorak-mapped keys
|
||||||
let g:use_dvorak = 1
|
let g:use_dvorak = 1
|
||||||
|
|
||||||
" YouCompleteMe config
|
" Deoplete config
|
||||||
let g:ycm_confirm_extra_conf = 0
|
call deoplete#custom#option({
|
||||||
if !exists('g:ycm_semantic_triggers')
|
\ 'camel_case': v:true,
|
||||||
let g:ycm_semantic_triggers = {}
|
\ })
|
||||||
endif
|
call deoplete#enable()
|
||||||
let g:ycm_semantic_triggers.tex = g:vimtex#re#youcompleteme
|
|
||||||
"let g:vimtex_view_method='zathura'
|
" Vim-Airline config
|
||||||
|
let g:Powerline_symbols = 'fancy'
|
||||||
|
let g:airline_powerline_fonts = 1
|
||||||
|
let g:airline_theme='solarized'
|
||||||
|
let g:airline#extensions#tabline#enabled = 1
|
||||||
|
" ALE integration
|
||||||
|
let g:airline#extensions#ale#enabled = 1
|
||||||
|
|
||||||
|
" vim-markdown plugin
|
||||||
|
let vim_markdown_preview_toggle=0
|
||||||
|
let vim_markdown_preview_browser='Chromium'
|
||||||
|
let vim_markdown_preview_use_xdg_open=1
|
||||||
|
let vim_markdown_preview_github=1
|
||||||
|
|
||||||
|
" LaTeX config
|
||||||
let g:tex_flavor='xelatex'
|
let g:tex_flavor='xelatex'
|
||||||
let g:vimtex_indent_enabled = 0 " auto-indentation is wrong and annoying
|
let g:vimtex_indent_enabled = 0 " auto-indentation is wrong and annoying
|
||||||
let g:syntastic_tex_checkers = ['chktex']
|
|
||||||
autocmd FileType tex silent VimtexCompile
|
autocmd FileType tex silent VimtexCompile
|
||||||
autocmd FileType tex setlocal spell
|
autocmd FileType tex setlocal spell
|
||||||
augroup vimtex
|
augroup vimtex
|
||||||
@ -136,35 +162,6 @@ augroup vimtex
|
|||||||
autocmd BufWritePost tex silent VimtexCompile
|
autocmd BufWritePost tex silent VimtexCompile
|
||||||
augroup END
|
augroup END
|
||||||
|
|
||||||
|
|
||||||
" Vim-Airline config
|
|
||||||
let g:Powerline_symbols = 'fancy'
|
|
||||||
let g:airline_powerline_fonts = 1
|
|
||||||
let g:airline_theme='solarized'
|
|
||||||
let g:airline#extensions#tabline#enabled = 1
|
|
||||||
let g:syntastic_always_populate_loc_list = 1
|
|
||||||
let g:syntastic_auto_loc_list = 1
|
|
||||||
let g:syntastic_check_on_open = 1
|
|
||||||
let g:syntastic_check_on_wq = 0
|
|
||||||
|
|
||||||
set statusline+=%#warningmsg#
|
|
||||||
set statusline+=%{SyntasticStatuslineFlag()}
|
|
||||||
set statusline+=%*
|
|
||||||
|
|
||||||
" vim-markdown plugin
|
|
||||||
let vim_markdown_preview_toggle=0
|
|
||||||
let vim_markdown_preview_browser='Chromium'
|
|
||||||
let vim_markdown_preview_use_xdg_open=1
|
|
||||||
let vim_markdown_preview_github=1
|
|
||||||
|
|
||||||
" Syntastic configuration
|
|
||||||
let g:syntastic_enable_highlighting = 1
|
|
||||||
let g:syntastic_enable_signs=1
|
|
||||||
let g:syntastic_always_populate_loc_list = 1
|
|
||||||
let g:syntastic_auto_loc_list = 1
|
|
||||||
let g:syntastic_check_on_open = 1
|
|
||||||
let g:syntastic_check_on_wq = 0
|
|
||||||
|
|
||||||
" Tagbar configuration
|
" Tagbar configuration
|
||||||
let g:tagbar_width = 50
|
let g:tagbar_width = 50
|
||||||
let g:tagbar_compact = 1
|
let g:tagbar_compact = 1
|
||||||
@ -304,6 +301,11 @@ cmap w!! w !sudo tee > /dev/null %
|
|||||||
map Q <nop>
|
map Q <nop>
|
||||||
|
|
||||||
|
|
||||||
autocmd FileType markdown setlocal ts=2 sts=2 sw=2 et
|
autocmd FileType c setlocal noet
|
||||||
autocmd FileType yaml setlocal ts=2 sts=2 sw=2 et indentkeys-=<:>
|
autocmd filetype c,h,cpp,hpp set colorcolumn=81
|
||||||
autocmd FileType gitcommit setlocal cc=72 et sw=4
|
autocmd filetype c,h,cpp,hpp match ErrorMsg '\%>80v.\+'
|
||||||
|
|
||||||
|
autocmd FileType jinja setlocal sts=2 sw=2 et
|
||||||
|
autocmd FileType markdown setlocal sts=2 sw=2 et
|
||||||
|
autocmd FileType yaml setlocal sts=2 sw=2 et indentkeys-=<:>
|
||||||
|
autocmd FileType gitcommit setlocal tw=72 et sw=4
|
||||||
|
Loading…
Reference in New Issue
Block a user