Skip to content

Instantly share code, notes, and snippets.

@hrdtbs
Created September 17, 2019 06:39
Show Gist options
  • Save hrdtbs/7f4f985f8af962e705d807edd914eeb3 to your computer and use it in GitHub Desktop.
Save hrdtbs/7f4f985f8af962e705d807edd914eeb3 to your computer and use it in GitHub Desktop.
vscode settings: go modules, gopls, golangci-lint
{
// Go Modules
"go.toolsEnvVars": {"GO111MODULE": "on"},
// Formatter
"go.useLanguageServer": true,
"go.alternateTools": {
"go-langserver": "gopls"
},
"go.languageServerExperimentalFeatures": {
"format": true,
"autoComplete": true
},
"[go]": {
"editor.snippetSuggestions": "none",
"editor.formatOnSave": true,
"editor.codeActionsOnSave": {
"source.organizeImports": true
},
},
"gopls": {
"usePlaceholders": true,
"enhancedHover": true
},
// Go Linter
"go.lintTool":"golangci-lint",
"go.lintFlags": [
"--fast"
]
}
@kcotten
Copy link

kcotten commented Dec 10, 2021

Thanks, saved me a lot of googling

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment