dotfiles/.vimrc

73 lines
1.7 KiB
VimL
Raw Normal View History

2020-09-07 14:17:34 -07:00
set nocompatible
set wildmenu
set nowrap
2020-09-07 14:17:34 -07:00
filetype off
2020-09-12 15:16:51 -07:00
autocmd BufRead,BufNewFile *.md,*.text,*.txt,*.tex setlocal spell
2020-09-07 14:17:34 -07:00
set complete+=kspell
set clipboard=unnamedplus
set rtp+=~/.vim/bundle/Vundle.vim
call vundle#begin()
""""""""""""""""""""""""""""""""""""""""""""""""""
Plugin 'gmarik/Vundle.vim'
" Python
Plugin 'vim-scripts/indentpython.vim'
Plugin 'Vimjas/vim-python-pep8-indent'
Plugin 'vim-python/python-syntax'
" Ease of use
Plugin 'dkarter/bullets.vim'
Plugin 'tpope/vim-surround'
" Latex
Plugin 'xuhdev/vim-latex-live-preview'
"""""""""""""""""""""""""""""""""""""""""""""""""
call vundle#end()
colorscheme wal
syntax on
syntax enable
set t_Co=256
set autoindent
set smartindent
set shiftwidth=4
set expandtab
set number
set tabstop=4
let g:python_highlight_all = 1
set encoding=utf-8
set termencoding=utf-8
set showmatch
set incsearch
let &t_SI .= "\<Esc>[?2004h"
let &t_EI .= "\<Esc>[?2004l"
inoremap <special> <expr> <Esc>[200~ XTermPasteBegin()
2020-09-11 23:48:00 -07:00
nnoremap <F5> "=strftime("%x - %X")<CR>P
inoremap <F5> <C-R>=strftime("%x - %X")<CR>
inoremap <F4> <C-R>\//==============================//<CR>
inoremap <F6> <C-R>\\begin{center}\line(1,0){250}\end{center}<CR>
2020-09-12 15:16:51 -07:00
autocmd FileType tex nnoremap <buffer> <C-e> :!clear && sh ~/.scripts/compile-scripts/latex.sh "%" <Enter>
autocmd FileType c nnoremap <buffer> <C-e> :!clear && sh ~/.scripts/compile-scripts/c.sh "%" <Enter>
autocmd FileType py nnoremap <buffer> <C-e> :!clear && sh ~/.scripts/compile-scripts/python.sh "%" <Enter>
autocmd FileType cpp nnoremap <buffer> <C-e> :!clear && sh ~/.scripts/compile-scripts/cpp.sh "%" <Enter>
2020-09-11 23:48:00 -07:00
2020-09-07 14:17:34 -07:00
function! XTermPasteBegin()
set pastetoggle=<Esc>[201~
set paste
return ""
endfunction
let g:livepreview_previewer = 'zathura'
2020-09-12 15:16:51 -07:00
i