install global package golang 1

install global package golang

# This is the default GOPATH, you should confirm with the 'go env' command
export GOPATH=$HOME/go
export PATH=$PATH:$GOROOT/bin:$GOPATH/bin

Here is what the above code is Doing:
1. It’s setting the GOROOT environment variable to the location of your Go installation.
2. It’s setting the GOPATH environment variable to the location of your workspace.
3. It’s adding the bin subdirectories of both GOROOT and GOPATH to your PATH.

Similar Posts