Add ledger Vim/Pathogen bundle
This commit is contained in:
parent
1a24501ca0
commit
ff8c074079
4 changed files with 769 additions and 0 deletions
28
vim/bundle/ledger/compiler/ledger.vim
Normal file
28
vim/bundle/ledger/compiler/ledger.vim
Normal file
|
@ -0,0 +1,28 @@
|
|||
" Vim Compiler File
|
||||
" Compiler: ledger
|
||||
" by Johann Klähn; Use according to the terms of the GPL>=2.
|
||||
" vim:ts=2:sw=2:sts=2:foldmethod=marker
|
||||
|
||||
if exists("current_compiler")
|
||||
finish
|
||||
endif
|
||||
let current_compiler = "ledger"
|
||||
|
||||
if exists(":CompilerSet") != 2
|
||||
command -nargs=* CompilerSet setlocal <args>
|
||||
endif
|
||||
|
||||
" default value will be set in ftplugin
|
||||
if ! exists("g:ledger_bin") || empty(g:ledger_bin) || ! executable(split(g:ledger_bin, '\s')[0])
|
||||
finish
|
||||
endif
|
||||
|
||||
" %-G throws away blank lines, everything else is assumed to be part of a
|
||||
" multi-line error message.
|
||||
CompilerSet errorformat=%-G,%EWhile\ parsing\ file\ \"%f\"\\,\ line\ %l:%.%#,%ZError:\ %m,%C%.%#
|
||||
CompilerSet errorformat+=%tarning:\ \"%f\"\\,\ line\ %l:\ %m
|
||||
|
||||
" unfortunately there is no 'check file' command,
|
||||
" so we will just use a query that returns no results. ever.
|
||||
exe 'CompilerSet makeprg='.substitute(g:ledger_bin, ' ', '\\ ', 'g').'\ -f\ %\ reg\ not\ ''.*''\ \>\ /dev/null'
|
||||
|
Loading…
Add table
Add a link
Reference in a new issue