Tag: vscode

go: cannot find main module, but found .git config to create a module there, run: go mod

go: cannot find main module, but found .git/config to create a module there, run: go mod This problem occurred in a monorepo opened in VSCode. The repo has many services placed in isolated directories with respective go.mod files. I realized from various sources that the problem is from two places: Move the mono repo under $GOPATH/src. The ~/.zshrc or ~/.bashrc…

How to Add Multiple Directories in GOPATH with VSCode?

Since go versions keep moving up, maintaining GOPATH inside a Go installation path is a pain. export GOPATH=/home/a-user/go/1.14.9 ls /home/a-user/go/1.14.0/src bitbucket.org github.com go.uber.org golang.org gopkg.in Adding multiple directories in GOPATH Create a directory e.g. for work mkdir $HOME/mywork GOPATH assumes a structure in the directory, so create three directories inside. ls $HOME/mywork bin pkg src You will do all your…

VSCode Plugins for Golang Development

Rich Go language support for Visual Studio Code Theme: Dark Knight: A simple dark theme for Golang projects Git Blame & Git History Postfix templates for Golang Adds go to implementation on context menu All-language autocompleter — TabNine uses machine learning to help you write code faster. This is a minimal list of Go development extensions in my opinion.

vscode: How to Customize a Settings and Theme

You can change almost everything in vscode settings. I wasn’t happy with terminal settings, so found very useful hints on changing them. A complete list of coding font is available here. My current settings.json is as follows: { “telemetry.enableTelemetry”: false, “telemetry.enableCrashReporter”: false, “editor.renderWhitespace”: “all”, “editor.wordWrap”: “on”, “editor.fontLigatures”: true, “editor.fontFamily”: “‘Hack'”, “editor.minimap.enabled”: false, “breadcrumbs.enabled”: false, “files.autoSave”: “afterDelay”, “workbench.statusBar.visible”: true, “workbench.activityBar.visible”: true,…

Top 5 VSCode Extensions for Vim Lovers

Vim Extensions vscodevim: Vim emulation for Visual Studio Code Better Align (: + = in visual mode) Language Specific Extensions C/C++ C/C++ IntelliSense, debugging, and code browsing. Better C++: better-cpp-syntax Golang Go Microsoft Go Group Imports Go Critic Python Python Microsoft Python Extension Pack Ruby Ruby for Visual Studio Code Rubocop Ruby Solargraph Themes Github Plus Winter Is Coming (Light…