diff options
Diffstat (limited to 'ale_linters/go/gometalinter.vim')
-rw-r--r-- | ale_linters/go/gometalinter.vim | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/ale_linters/go/gometalinter.vim b/ale_linters/go/gometalinter.vim index eed9550a..ac33a9f3 100644 --- a/ale_linters/go/gometalinter.vim +++ b/ale_linters/go/gometalinter.vim @@ -13,14 +13,12 @@ function! ale_linters#go#gometalinter#GetCommand(buffer) abort " BufferCdString is used so that we can be sure the paths output from gometalinter can " be calculated to absolute paths in the Handler if l:lint_package - return ale#path#BufferCdString(a:buffer) - \ . ale#go#EnvString(a:buffer) + return ale#go#EnvString(a:buffer) \ . '%e' \ . (!empty(l:options) ? ' ' . l:options : '') . ' .' endif - return ale#path#BufferCdString(a:buffer) - \ . ale#go#EnvString(a:buffer) + return ale#go#EnvString(a:buffer) \ . '%e' \ . ' --include=' . ale#Escape(ale#util#EscapePCRE(l:filename)) \ . (!empty(l:options) ? ' ' . l:options : '') . ' .' @@ -53,6 +51,7 @@ endfunction call ale#linter#Define('go', { \ 'name': 'gometalinter', \ 'executable': {b -> ale#Var(b, 'go_gometalinter_executable')}, +\ 'cwd': '%s:h', \ 'command': function('ale_linters#go#gometalinter#GetCommand'), \ 'callback': 'ale_linters#go#gometalinter#Handler', \ 'lint_file': 1, |