@@ -37,7 +37,7 @@ coc-settings.json
37
37
" command" : " golangci-lint-langserver" ,
38
38
" filetypes" : [" go" ],
39
39
" initializationOptions" : {
40
- " command" : [" golangci-lint" , " run" , " --enable-all" , " --disable" , " lll" , " --out-format" , " json" ]
40
+ " command" : [" golangci-lint" , " run" , " --enable-all" , " --disable" , " lll" , " --out-format" , " json" , " --issues-exit-code=1 " ]
41
41
}
42
42
}
43
43
}
@@ -52,7 +52,7 @@ augroup vim_lsp_golangci_lint_langserver
52
52
autocmd User lsp_setup call lsp#register_server({
53
53
\ 'name': 'golangci-lint-langserver',
54
54
\ 'cmd': {server_info->['golangci-lint-langserver']},
55
- \ 'initialization_options': {'command': ['golangci-lint', 'run', '--enable-all', '--disable', 'lll', '--out-format', 'json']},
55
+ \ 'initialization_options': {'command': ['golangci-lint', 'run', '--enable-all', '--disable', 'lll', '--out-format', 'json', '--issues-exit-code=1' ]},
56
56
\ 'whitelist': ['go'],
57
57
\ })
58
58
augroup END
@@ -74,7 +74,7 @@ if not configs.golangcilsp then
74
74
cmd = {' golangci-lint-langserver' },
75
75
root_dir = lspconfig .util .root_pattern (' .git' , ' go.mod' ),
76
76
init_options = {
77
- command = { " golangci-lint" , " run" , " --enable-all" , " --disable" , " lll" , " --out-format" , " json" };
77
+ command = { " golangci-lint" , " run" , " --enable-all" , " --disable" , " lll" , " --out-format" , " json" , " --issues-exit-code=1 " };
78
78
}
79
79
};
80
80
}
@@ -90,7 +90,7 @@ lspconfig.golangci_lint_ls.setup {
90
90
(with-eval-after-load 'lsp-mode
91
91
(lsp-register-custom-settings
92
92
'(("golangci-lint.command"
93
- ["golangci-lint" "run" "--enable-all" "--disable" "lll" "--out-format" "json"])))
93
+ ["golangci-lint" "run" "--enable-all" "--disable" "lll" "--out-format" "json" "--issues-exit-code=1" ])))
94
94
95
95
(lsp-register-client
96
96
(make-lsp-client :new-connection (lsp-stdio-connection
0 commit comments