Home > Development Tools > VSCode > What should I do if the installation of vscode golint fails?

What should I do if the installation of vscode golint fails?

藏色散人
Release: 2019-11-14 09:25:30
Original
3165 people have browsed it

What should I do if the installation of vscode golint fails?

What should I do if golint installation fails?

Origin of the problem:

Due to domestic network blocking, golang.org was harmonized, and it caught up with 7.1. In a harmonious society with dual efforts, various FQs are unsolvable, so there are The following.

Solution overview:

Go to github to download the source code of go tools and golint to the local directory, and install it with the go install command.

Recommended tutorial: vscode tutorial

Specific method:

1. Create the golang.org folder in the %GOPATH%\src\ directory , and create a new x folder. The directory is "%GOPATH\src\golang.org\x\"

2. After completing the directory switch, start downloading the plug-in package: git clone https://github.com/golang/tools.git tools

3. After execution, there will be an additional tools folder.

4. Open the vsCode terminal, switch to the terminal, enter the "%GOPATH" directory, 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/josharian/impl
    go install github.com/rogpeppe/godef
    go install github.com/sqs/goreturns
    go install github.com/golang/lint/golint
    go install github.com/cweill/gotests/gotests
    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/josharian/impl
    go install github.com/rogpeppe/godef
    go install github.com/sqs/goreturns
    go install github.com/cweill/gotests/gotests
Copy after login
<span style="font-size:10px;"><strong>继续安装golint</strong>
在cmd中切换到“GOPATH”目录,执行 git clone https://github.com/golang/lint.git,将glint也下载到本地
复制%GOPATH%\src\github.com\golang\lint目录到%GOPATH%\src\golang.org\x,不复制源码不同意,算了,复制
执行:go install golang.org\x\lint\golint,安装完毕</span>
Copy after login
<strong><span style="font-size:10px;">至此,全部go插件都安装完毕,重启vscode,看效果,不会有提示再弹出了</span></strong>
Copy after login

The above is the detailed content of What should I do if the installation of vscode golint fails?. For more information, please follow other related articles on the PHP Chinese website!

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template