Build go language development environment and installation problem solution under Mac

1. Install Golang SDK

http://golang.org

Download the latest installation package, then double-click to install.

After the installation is complete, open the terminal,

Enter go, or go version (to view the installation version) and the following information appears, indicating that the installation is successful:

 

Abnormal situation: display zsh:command not found

Solution:
1. Enter the directory in the terminal: cd /usr/local to check whether your go exists

Because the figure shows that it contains go, it means that the installation is successful.
2. Then enter cd /usr/local/bin to check whether the reference exists

It can be seen in the figure that there is no go file
3. Use the In command to set up a synchronous link in the terminal setting:
sudo ln -fs /usr/local/go/bin/go /usr/local/bin/go

Enter go, or go version (to view the installation version) and the following information appears, indicating that the installation is successful:

Guess you like

Origin blog.csdn.net/heqiushuang110/article/details/129996356