diff options
author | Adam Stankiewicz <sheerun@sher.pl> | 2020-05-28 11:09:19 +0200 |
---|---|---|
committer | Adam Stankiewicz <sheerun@sher.pl> | 2020-05-28 11:09:19 +0200 |
commit | 224a6348f99167c9d72b5922686d388ae872ff7e (patch) | |
tree | 328383c5ca7e8fa59a47ba5bb0709676c3964677 /compiler | |
parent | 00c3f0294575a91524c3f3b6cba37839716b48a2 (diff) | |
download | vim-polyglot-224a6348f99167c9d72b5922686d388ae872ff7e.tar.gz vim-polyglot-224a6348f99167c9d72b5922686d388ae872ff7e.zip |
Update
Diffstat (limited to 'compiler')
-rw-r--r-- | compiler/haml.vim | 32 | ||||
-rw-r--r-- | compiler/ledger.vim | 8 |
2 files changed, 6 insertions, 34 deletions
diff --git a/compiler/haml.vim b/compiler/haml.vim deleted file mode 100644 index e942631f..00000000 --- a/compiler/haml.vim +++ /dev/null @@ -1,32 +0,0 @@ -if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'haml') == -1 - -" Vim compiler file -" Compiler: Haml -" Maintainer: Tim Pope <vimNOSPAM@tpope.org> -" Last Change: 2016 Aug 29 - -if exists("current_compiler") - finish -endif -let current_compiler = "haml" - -if exists(":CompilerSet") != 2 " older Vim always used :setlocal - command -nargs=* CompilerSet setlocal <args> -endif - -let s:cpo_save = &cpo -set cpo-=C - -CompilerSet makeprg=haml - -CompilerSet errorformat= - \Haml\ %trror\ on\ line\ %l:\ %m, - \Syntax\ %trror\ on\ line\ %l:\ %m, - \%-G%.%# - -let &cpo = s:cpo_save -unlet s:cpo_save - -" vim:set sw=2 sts=2: - -endif diff --git a/compiler/ledger.vim b/compiler/ledger.vim index 7a9bc305..8d441af9 100644 --- a/compiler/ledger.vim +++ b/compiler/ledger.vim @@ -17,6 +17,10 @@ if exists(':CompilerSet') != 2 command -nargs=* CompilerSet setlocal <args> endif +if !exists('g:ledger_main') + let g:ledger_main = '%' +endif + if !g:ledger_is_hledger " Capture Ledger errors (%-C ignores all lines between "While parsing..." and "Error:..."): CompilerSet errorformat=%EWhile\ parsing\ file\ \"%f\"\\,\ line\ %l:,%ZError:\ %m,%-C%.%# @@ -24,9 +28,9 @@ if !g:ledger_is_hledger CompilerSet errorformat+=%tarning:\ \"%f\"\\,\ line\ %l:\ %m " Skip all other lines: CompilerSet errorformat+=%-G%.%# - exe 'CompilerSet makeprg='.substitute(g:ledger_bin, ' ', '\\ ', 'g').'\ -f\ %\ '.substitute(g:ledger_extra_options, ' ', '\\ ', 'g').'\ source\ %' + exe 'CompilerSet makeprg='.substitute(g:ledger_bin, ' ', '\\ ', 'g').'\ -f\ ' . shellescape(expand(g:ledger_main)) . '\ '.substitute(g:ledger_extra_options, ' ', '\\ ', 'g').'\ source\ ' . shellescape(expand(g:ledger_main)) else - exe 'CompilerSet makeprg=('.substitute(g:ledger_bin, ' ', '\\ ', 'g').'\ -f\ %\ print\ '.substitute(g:ledger_extra_options, ' ', '\\ ', 'g').'\ >\ /dev/null)' + exe 'CompilerSet makeprg=('.substitute(g:ledger_bin, ' ', '\\ ', 'g').'\ -f\ ' . shellescape(expand(g:ledger_main)) . '\ print\ '.substitute(g:ledger_extra_options, ' ', '\\ ', 'g').'\ >\ /dev/null)' endif endif |