Golang Tutorial-1.1 Multi-platform installation Golang

Source: Internet
Author: User

This article is the first Golang language learning tutorial

What is Golang?

The individual thinks that the novice has no understanding of the real features, and so on, so that they can really understand after the real learning. So the following conceptual things need only a general understanding.

The go language is a new programming language launched by Google, which makes it easy to construct simple, reliable and efficient software.

Open source in November 2009, released the stable version of Go 1 earlier in 2012. Now the go development is completely open and has an active community.

Go language Features

    • Simple, fast and secure
    • Parallel, fun, open source
    • Memory management, v array security, quick and easy

Go language Installation

Golang supports three platforms: Mac,windows and Linux (not just these three, but also other mainstream platforms).

Download Address

Mac OS

After you download the installation program. Double-click to start the installation and follow the installation prompts, the Golang will be installed /usr/local/go in the directory, and the /usr/local/go/bin folder will be added to the PATH environment variable.

Windows

After you download the MSI Setup program. Double-click to start the installation and follow the installation prompts, the Golang will be installed C:\Go in the directory, and the c:\Go\bin directory will be added to your PATH environment variables.

Linux

Download the tar package file and unzip it to /usr/local .
Perform

echo "export PATH=/usr/local/go/bin:$PATH" >~/.bashrcsource ~/.bashrc

The go has been successfully installed Linux .

Run the command go directly and the usage will pop up to indicate a successful configuration

[Root@localhost ~]# GoGo is a tool for managing Go source code. Usage:go command [arguments]the commands are:build compile packages and dependencies clean remove O bject files and cached files Doc show documentation for package or symbol ENV print Go environment I Nformation Bug start a bug report fix update packages to use new APIs FMT gofmt (reformat ) package sources generate generate Go files by processing source get download and install packages and D Ependencies install compile and install packages and Dependencies list List packages run Compi    Le and run Go program test test Packages Tool run specified Go tool version print go version Vet report likely mistakes in Packagesuse ' Go help [command] ' For more information about a command. Additional help Topics:c calling between Go and C Buildmode build modes CACHe build and test caching filetype file types gopath gopath environment variable environment ENVIRO    Nment variables Importpath Import path Syntax Packages package lists Testflag testing flags TestFunc Testing FunctionsUse "Go help [topic]" For more information on that topic.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.