What is Go Lang ?
Go is an open source programming language that makes it easy to build simple, reliable, and efficient software.
You can read more about Go Lang From Here : https://golang.org/
Follow below Steps to Setup Go Lang on Windows Machine :
1. Download the appropriate go version for your windows (x64 / x86) from here https://golang.org/dl/
2. Extract downloaded zip.
3. Copy Go folder from extracted folder to C:\Go to make thing easier.
4.Ensure the Go binaries (found in
Easy way to confirm your path is by typing go version in command line tool.
5.Setup your Go workspace. This consists of three folders at the root: \bin,\pkg & \src.
6.Create the GOPATH environment variable and reference your Go workspace path. To add, click
Set the variable name to
Check quickly if path has been set correctly or not from command line:
7. Create new file hello.go at C:\Projects\Go\bin directory and write following code into it:
8. That's it you are ready to run your hello world program of go Lang. Just go to your projects folder \bin directory from command line and type go run hello.go.
Go is an open source programming language that makes it easy to build simple, reliable, and efficient software.
You can read more about Go Lang From Here : https://golang.org/
Follow below Steps to Setup Go Lang on Windows Machine :
1. Download the appropriate go version for your windows (x64 / x86) from here https://golang.org/dl/
2. Extract downloaded zip.
3. Copy Go folder from extracted folder to C:\Go to make thing easier.
4.Ensure the Go binaries (found in
C:\Go\bin
) are in your Path
system environment variables. To check click System
, Advanced system settings
, Environment Variables...
and open Path
under System variables
:5.Setup your Go workspace. This consists of three folders at the root: \bin,\pkg & \src.
6.Create the GOPATH environment variable and reference your Go workspace path. To add, click
System
, Advanced system settings
, Environment Variables...
and click New...
under System variables
:Set the variable name to
GOPATH
and value to your Go workspace path (e.g. C:\Projects\Go
):Check quickly if path has been set correctly or not from command line:
7. Create new file hello.go at C:\Projects\Go\bin directory and write following code into it:
8. That's it you are ready to run your hello world program of go Lang. Just go to your projects folder \bin directory from command line and type go run hello.go.
No comments:
Post a Comment