IDE for GoLang
Table of Contents
Intro
Okay, I started to learn a GoLang. After ridding tutorials from Go: Step by Step I need to practice.
I can use a notepad, but will it productivity and comfortable?
Absolutely not! Powerful instruments, like refactoring
, renaming
, code completion
and etc, helping us write code more quickly this better quality.
Choosing IDE
I need a powerful and useful tool for write that code.
Right now, I see only very short list of IDE for write Go code:
LiteIDE
IDE have very specific UI. Skipping.
vim
Old school. But for me it’s terrible instrument. Skipping.
GoLand
Very powerful IDE, but cost some money. Thinking about it later. Skipping.
VS Code or Codium
This variant is better for me right now. But that should I choose?
Rob O’Leary write a post about comparanse between this products. Also a lot of post available in the internet.
And I choose a Codium.
Install Codium
Let`s install Codium via simple command
brew install --cask vscodium
Install necessary extensions
Now, install extensions that help us do our job with more more productivity.
Open Codium
, click on Extensions
and install:
Go
- the basic extensions for addGoLang
support forCodium
;Go mock
- help us generate a mock this mockery.
All right! I have an IDE and extensions. Try to write some code?
No! Before write some code, we`l install additional packages for better development.
Install usefull package
Lint
Well, Is a checking code wich lint a good ide? Sure. That`s mean that we need golangci-lint checker! Install it with:
brew install golangci-lint
For checking code simply run in folder with code a command:
golangci-lint run
Static check
Now, how about a static check? Wery good idea:
brew install staticcheck
For use it, run in folder with code a command:
staticcheck ./...
Conclusions
- I install Codium IDE;
Codium
Go extensions;- Some useful packages.
Hooray! Now, I’m ready to write code!