Fixed golang plug in dependency installation failure in vscode
- 2020-07-21 08:24:15
- OfStack
vscode installed in
ms-vscode.go
Support for the go language can be turned on after the plug-in,
ms-vscode.go
Plug-ins need to rely on 1 of the tools, installation is completed prompt
gocode
go-outline
go-symbols
guru
gorename
gocode-gomod
goreturns
golint
Installing github.com/ramya-rao-a/go-outline FAILED
Due to network reasons, some dependent tools cannot be installed normally, so manual installation is needed.
Here are the steps for manually installing the tools:
Under %GOPATH%\src\ directory, set up the path golang.org \x
GOPATH into % % \ src \ golang org \ x, download need tool source git clone https: / / github com/golang/tools git tools
When clone is complete, an tools folder will be generated so that the source code for the tool is ready
Go to %GOPATH% and execute
go install github.com/ramya-rao-a/go-outline
go install github.com/acroca/go-symbols
go install golang.org/x/tools/cmd/guru
go install golang.org/x/tools/cmd/gorename
go install github.com/rogpeppe/godef
go install github.com/sqs/goreturns
go install github.com/cweill/gotests/gotests
If there are errors in the above execution, please use go get before using the above command
go get github.com/rogpeppe/godef
go get github.com/cweill/gotests/gotests
Separate processing golint golint source located https: / / github com/golang/lint, enter the % GOPATH % \ src \ golang org \ x executed after git clone https: / / github com golang/lint download golint need the source code
Go to %GOPATH% and execute
go install golang.org/x/lint/golint
This completes the installation of the tools that the golang plug-in for vscode relies on.
conclusion