Last active
          June 26, 2025 16:07 
        
      - 
      
- 
        Save extremecoders-re/9e8e515aed82d95c205df45dffa8f5fd to your computer and use it in GitHub Desktop. 
Revisions
- 
        extremecoders-re revised this gist Apr 13, 2024 . 1 changed file with 2 additions and 0 deletions.There are no files selected for viewingThis file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -13,6 +13,8 @@ Note the current goroot path Add the path to vscode *settings.json* (Workspace or Global) For workspace: config is saved in `.vscode/settings.json` ``` { "go.goroot": "/home/ec/miniconda3/envs/go/go", 
- 
        extremecoders-re revised this gist Mar 30, 2023 . 1 changed file with 7 additions and 1 deletion.There are no files selected for viewingThis file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -30,4 +30,10 @@ However the installation of some tool will surely fail which needs to be install (goenv) $ go install -v golang.org/x/tools/gopls@latest ``` The exact tools which failed and the corresponding command to install them can be found in the Output panel in VScode. ## References - https://github.com/golang/vscode-go/blob/master/docs/settings.md - https://github.com/golang/vscode-go/blob/master/docs/gopath.md - https://www.jetbrains.com/help/go/configuring-goroot-and-gopath.html - https://github.com/RcppCore/Rcpp/issues/770#issuecomment-346716808 
- 
        extremecoders-re created this gist Mar 30, 2023 .There are no files selected for viewingThis file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,33 @@ ``` $ conda create -n goenv go $ conda activate goenv (goenv) $ conda install -c conda-forge gxx_linux-64 # Required for the vscode go extension ``` Note the current goroot path ``` (goenv) $ go env GOROOT /home/ec/miniconda3/envs/go/go ``` Add the path to vscode *settings.json* (Workspace or Global) ``` { "go.goroot": "/home/ec/miniconda3/envs/go/go", } ``` Next install the Go plugin for VScode. It will prompt to install a few tools. Click on "Install All". However the installation of some tool will surely fail which needs to be installed manually like. ``` (goenv) $ go install -v github.com/cweill/gotests/[email protected] (goenv) $ go install -v github.com/haya14busa/goplay/cmd/[email protected] (goenv) $ go install -v github.com/go-delve/delve/cmd/dlv@latest (goenv) $ go install -v honnef.co/go/tools/cmd/staticcheck@latest (goenv) $ go install -v golang.org/x/tools/gopls@latest ``` The exact tools which failed and the corresponding command to install them can be found in the Output panel in VScode.