Projekat

Općenito

Profil

Podrška #30438 » harbour.vim

Ernad Husremović, 28.02.2013 15:55

 
"============================================================================
"File: harbour.vim
"Description: Javascript syntax checker - using harbour
"Maintainer: Martin Grenfell <martin.grenfell at gmail dot com>
"License: This program is free software. It comes without any warranty,
" to the extent permitted by applicable law. You can redistribute
" it and/or modify it under the terms of the Do What The Fuck You
" Want To Public License, Version 2, as published by Sam Hocevar.
" See http://sam.zoy.org/wtfpl/COPYING for more details.
"============================================================================
if exists("g:loaded_syntastic_clipper_harbour_checker")
finish
endif
let g:loaded_syntastic_clipper_harbour_checker=1

if !exists("g:syntastic_clipper_harbour_conf")
let g:syntastic_clipper_harbour_conf = ""
endif

function! SyntaxCheckers_clipper_harbour_IsAvailable()
return executable('harbour')
endfunction

function! SyntaxCheckers_clipper_harbour_GetLocList()
let makeprg = syntastic#makeprg#build({
\ 'exe': 'harbour',
\ 'post_args': s:Args(),
\ 'subchecker': 'harbour' })

"test.prg:1: error E0030 Syntax error syntax error at '+'
let errorformat = '%f:%l:%m'
return SyntasticMake({ 'makeprg': makeprg, 'errorformat': errorformat, 'defaults': {'bufnr': bufnr('')} })
endfunction

function s:Args()
return '-ge1 -w3'
endfunction

call g:SyntasticRegistry.CreateAndRegisterChecker({
\ 'filetype': 'clipper',
\ 'name': 'harbour'})

    (1-1/1)