gofmt fixer for Go#970
Conversation
w0rp
left a comment
There was a problem hiding this comment.
You need to add entries to the README and the help file.
Have a look at whatever Travis is saying.
|
|
||
| return { | ||
| \ 'command': ale#Escape(l:executable) | ||
| \ . '-l -w' |
There was a problem hiding this comment.
You're missing a space before -l here.
| AssertEqual | ||
| \ { | ||
| \ 'read_temporary_file': 1, | ||
| \ 'command': ale#Escape(g:ale_go_gofmt_executable) |
There was a problem hiding this comment.
Use a string literal for the executable here instead.
| AssertEqual | ||
| \ { | ||
| \ 'read_temporary_file': 1, | ||
| \ 'command': ale#Escape(g:ale_go_gofmt_executable) |
There was a problem hiding this comment.
Use a string literal for the executable here too.
| \ { | ||
| \ 'read_temporary_file': 1, | ||
| \ 'command': ale#Escape(g:ale_go_gofmt_executable) | ||
| \ . '-l -w' |
There was a problem hiding this comment.
You missed the space in the test too.
|
Updated with your review. I didn’t add gofmt to the readme or the help files because it is already there as a linter. Should I mention that it also works as a fixer? |
|
Nah, that's okay. I didn't realise it was there. |
| number of linters known to be slow or consume a lot of resources. | ||
|
|
||
|
|
||
| =============================================================================== |
There was a problem hiding this comment.
Check out the Travis CI results. It's complaining because there's no table of contents entry which references this. You should add gofmt to the table of contents.
|
Now Travis is complaining because |
|
So that's what I did first and then again in the last commit, but Travis is still failing. Do you know something I might have missed on this? On a somewhat related note, I didn’t have these test fail locally because it seems like macOS’s version of Related line : |
|
The script is doing the right thing. You need to take your entire |
|
I wouldn't expect those scripts to run on Mac, because Macs use an ancient version of Bash and BSD userland stuff. I might be able to make them compatible some day, at the cost of some sanity, or just get them to run in Docker. |
|
Got it. Updated both the TOC and the order in the help files, and squash the relevant commits. LMK if something else is needed. |
w0rp
left a comment
There was a problem hiding this comment.
This is all fine and dandy. Thank you for your work on this. 👍
|
Cheers! 🍻 |
|
Cool 🎉 thanks! |
* upstream/master: Get more command callback tests to pass on Windows Add all possible config files for prettier gofmt fixer for Go (dense-analysis#970) Fix dense-analysis#964 - Remove signs when multiple signs end up on a single line Fix typos Get tslint and xmllint command callback tests to pass in Windows Add a Scripts dir for tests on Windows Get fixer tests to work on Windows Use local versions of yapf on Windows, and get the callback tests to pass Fix Flow and Idris tests for Windows Get the mcsc handler tests to pass on Windows Added g:ale_php_phpstan_configuration option Fix an issue with the check-supported-tools-tables script Implemented review recommendations Added advanced c-sharp linter Added advanced c-sharp linter There seems to be a bug in eslint that causes the `--config` option to not detect node_modules correctly. The `-c` option, however, works fine. Move dialect setting before user options (shellcheck)
Hello, this PR adds
gofmtas a fixer for Go.