latex formatter added

master
TiynGER 5 years ago
parent 6fbddba8eb
commit 098e5b0937

@ -27,7 +27,10 @@ srd() { find ~/ownCloud/* -type f | grep ".pdf" | fzf | xargs -r $READER ;}
alias grep="grep --color=auto" alias grep="grep --color=auto"
# haste # haste
haste() { a=$(cat); curl -X POST -s -d "$a" https://paste.tiyn.eu/documents | awk -F '"' '{print "https://paste.tiyn.eu/"$4}'; } haste() {
a=$(cat);
curl -X POST -s -d "$a" https://paste.tiyn.eu/documents | awk -F '"' '{print "https://paste.tiyn.eu/"$4}';
}
#khal #khal
alias calendar="khal" alias calendar="khal"

@ -74,18 +74,6 @@ let g:vim_markdown_no_default_key_mappings=1
" End Plugin section " End Plugin section
" Start Formatting section
autocmd FileType java,python,c noremap <F8> gggqG
au FileType python setlocal formatprg=autopep8\ -
au FileType java setlocal formatprg=google-java-format\ -
au FileType c setlocal formatprg=astyle\ --mode=c
" End Formatting section
let mapleader ="," let mapleader =","
set go=a set go=a
@ -96,7 +84,6 @@ set clipboard+=unnamedplus
set wildmode=longest,list,full set wildmode=longest,list,full
" Setting Tab-length " Setting Tab-length
set expandtab set expandtab
set tabstop=4
set softtabstop=4 set softtabstop=4
set shiftwidth=4 set shiftwidth=4
" Splits open at the bottom and right, which is non-retarded, unlike vim defaults. " Splits open at the bottom and right, which is non-retarded, unlike vim defaults.
@ -161,3 +148,19 @@ vnoremap <C-c> "+y
cnoremap w!! execute 'silent! write !sudo tee % >/dev/null' <bar> edit! cnoremap w!! execute 'silent! write !sudo tee % >/dev/null' <bar> edit!
" Alias for replacing " Alias for replacing
nnoremap S :%s//gI<Left><Left><Left> nnoremap S :%s//gI<Left><Left><Left>
" Start Formatting section
autocmd FileType java,python,c,tex,latex noremap <F8> gggqG
au FileType python setlocal formatprg=autopep8\ -
au FileType java setlocal formatprg=google-java-format\ -
autocmd FileType java setlocal shiftwidth=2 softtabstop=2
au FileType c setlocal formatprg=astyle\ --mode=c
au FileType tex,latex setlocal formatprg=latexindent\ -
" End Formatting section

Loading…
Cancel
Save