Go-tools: Add flag to output absolute path

Created on 24 Feb 2017  ·  4Comments  ·  Source: dominikh/go-tools

I'm wondering if is it possible to add flags to output absolute path instead of relative.
I use vim with plugin called Neomake. It can execute linters like yours. But it expect absolute path

wontfix

Most helpful comment

How does neomake deal with other tools, such as go build, that use relative paths and do not provide such a flag?

Tools like neomake should really be able to understand relative paths, considering they are relative to the current working directory and thus very easy to deal with.

All 4 comments

I added pull request about it. Please, take a look: https://github.com/dominikh/go-tools/pull/44

Note, neomake shouldn't require absolute paths, as I have it working with gometalinter in github.com/neomake/neomake/pull/795 and gometalinter works with relative paths. Specifically I think it's this line that adds base path to make relative path absolute https://github.com/neomake/neomake/pull/795/files#diff-8d275594f8173d629ed92ab8d0d43eafR61

How does neomake deal with other tools, such as go build, that use relative paths and do not provide such a flag?

Tools like neomake should really be able to understand relative paths, considering they are relative to the current working directory and thus very easy to deal with.

Ou, thanks, @bradleyfalzon!
Code from pull request is works for me
Just need to add to all makers

'cwd': '%:h',
'mapexpr': 'neomake_bufdir . "/" . v:val',

@dominikh Yeap, you're right. BTW, thanks for great tooling!

Was this page helpful?
0 / 5 - 0 ratings