Assalaamu’alaykum Warahmatullahi Wabarakaatuh guys.
This is my first episode about golang programming language. In this article i’ll show you how to setup golang in your environment and how to use it.
Download golang here:
Go is an open source programming language that makes it easy to build simple, reliable, and efficient software.
After you download it, double click and wait until the process is complete. Or you can install golang in another way.
Open terminal and write this command:
$ curl -o golang.pkg https://dl.google.com/go/go1.13.3.darwin-amd64.pkg
After package downloaded, execute it with this command:
$ sudo open golang.pkg
Setup Go Workspace open file .bash_profile. If you don’t know to edit it. You can follow this article:
My Mac OSX Bash Profile
I've spent years curating a collection of Mac bash aliases and shortcuts to make my life easier. My full .bash_profile…
You need to register 3 environment variables as GOROOT, GOPATH, and PATH.
GOROOT is the location of your golang installation.
$ export GOROOT=/usr/local/go
GOPATH is the location of your golang project.
$ export GOPATH=$HOME/YOUR PROJECTS PATH
So finally set the PATH variable to access go binary system-wide.
$ export PATH=$GOPATH/bin:$GOROOT/bin:$PATH
You can see detail configuration in this article.
How To Install Go 1.13 on MacOS - TecAdmin
Go is an open-source programming language developed by a team at Google. It provides easy to build simple, reliable…
Tutorial and Example
You can learning golang programming language from the source below:
The Go Playground
The Go Playground is a web service that runs on golang.org's servers. The service receives a Go program, vets…
The Go programming language is an open source project to make programmers more productive. Go is expressive, concise…
Go 1.13 API documentation with instant search, offline support, keyboard shortcuts, mobile version, and more.
Or you can learn basic golang programming language from the Telusko channel in youtube. I think this channel is very easy for learning golang.
And you can try my example code from this repository:
You can't perform that action at this time. You signed in with another tab or window. You signed out in another tab or…
That’s it how to install golang and try basic programming with it. I think it’s enough. May be useful and Enjoy!.
Wassalaamu’alaykum Warahmatullahi Wabarakaatuh