All patches and comments are welcome. Please squash your changes to logical
commits before using git-format-patch and git-send-email to
patches@git.madduck.net.
If you'd read over the Git project's submission guidelines and adhered to them,
I'd be especially grateful.
2 runtime ale_linters/go/golangci_lint.vim
5 call ale#linter#Reset()
7 Execute (The golangci-lint handler should handle only typecheck lines as errors):
8 call ale#test#SetFilename('app/main.go')
15 \ 'text': 'typecheck - found packages main (main.go) and validator (validation.go) in ',
17 \ 'filename': ale#path#Simplify(expand('%:p:h') . '/main.go'),
22 \ 'text': 'typecheck - package validator_test; expected package main_test',
24 \ 'filename': ale#path#Simplify(expand('%:p:h') . '/validation_encoder_test.go'),
29 \ 'text': 'typecheck - package validator_test; expected package main_test',
31 \ 'filename': ale#path#Simplify(expand('%:p:h') . '/validation_error_test.go'),
36 \ 'text': 'gomnd - Magic number: 404, in <argument> detected',
38 \ 'filename': ale#path#Simplify(expand('%:p:h') . '/main.go'),
41 \ ale_linters#go#golangci_lint#Handler(bufnr(''), [
45 \ ' "FromLinter": "typecheck",',
46 \ ' "Text": "found packages main (main.go) and validator (validation.go) in ",',
48 \ ' "SourceLines": [',
52 \ ' "Filename": "main.go",',
57 \ ' "ExpectNoLint": false,',
58 \ ' "ExpectedNoLintLinter": ""',
61 \ ' "FromLinter": "typecheck",',
62 \ ' "Text": "package validator_test; expected package main_test",',
64 \ ' "SourceLines": [',
65 \ ' "package validator_test"',
68 \ ' "Filename": "validation_encoder_test.go",',
73 \ ' "ExpectNoLint": false,',
74 \ ' "ExpectedNoLintLinter": ""',
77 \ ' "FromLinter": "typecheck",',
78 \ ' "Text": "package validator_test; expected package main_test",',
80 \ ' "SourceLines": [',
81 \ ' "package validator_test"',
84 \ ' "Filename": "validation_error_test.go",',
89 \ ' "ExpectNoLint": false,',
90 \ ' "ExpectedNoLintLinter": ""',
93 \ ' "FromLinter": "gomnd",',
94 \ ' "Text": "Magic number: 404, in <argument> detected",',
96 \ ' "SourceLines": [',
97 \ ' "package validator_test"',
100 \ ' "Filename": "main.go",',
105 \ ' "ExpectNoLint": false,',
106 \ ' "ExpectedNoLintLinter": ""',
112 Execute (The golangci-lint handler should set proper filename):
113 call ale#test#SetFilename('app/cmd/server/main.go')
120 \ 'text': 'funlen - Function getConfig has too many statements (51 > 50)',
122 \ 'filename': ale#path#Simplify(expand('%:p:h') . '/main.go'),
125 \ ale_linters#go#golangci_lint#Handler(bufnr(''), [
129 \ ' "FromLinter": "funlen",',
130 \ ' "Text": "Function getConfig has too many statements (51 > 50)",',
131 \ ' "Severity": "",',
132 \ ' "SourceLines": [',
136 \ ' "Filename": "cmd/server/main.go",',
137 \ ' "Offset": 5374,',
141 \ ' "ExpectNoLint": false,',
142 \ ' "ExpectedNoLintLinter": ""',