Golang — Configuration on Mac OS

shah.hassan
2 min readOct 21, 2023

--

Step by Step

In one of recent product developments — our new Sr. Engineer introduced Go language to be the core part of the API layer. Other than boosting his confident & motivation (fresh-new-blood guy but his voice is heard), it’s part of my playbook to promote (pressure) consistent learning in the team. You live in tech universe & if you blink longer than 1 second, you’ll be left out.

So ya, the engineer inside me scratching my skin to come out & I spent few hours to dig into Go. Quite interesting.

Steps :

Go to https://go.dev/dl/

Complete installation

Set the correct PATH by updating ~/.zshrc :

export PATH=$PATH:/usr/local/go/bin

export PATH=$PATH:$GOPATH/bin

Terminal > run go version command

Visual Studio Code > Go extension

Type the following go scripts

Run go run hello.go command

Bonus

RESTful API — Fundamental

Reference

Create project folder

Create a new file called main.go

Run go run . command

--

--

shah.hassan
shah.hassan

Written by shah.hassan

Software engineering and film. All are work-in-progress.

No responses yet