golang development environment

1.1 go installation environment

  1, go download and install

      Official: https://golang.org/dl

      domestic:

        https://golang.google.cn/dl/

        https://www.golangtc.com/download

    Adjust the environment variables go

      My Computer -> Advanced -> Environment Variables

      1. First make the installation go into the bin directory of the Path environment variable, and add the storage location of our code ( system variable path path )

          C: \ Go \ bin # go AnSoro径

          C: \ onlineGo # code we store path

      2. Specify the directory go compiler installed ( that is, the path of the user variables GOROOT installed by default )

          C:\go

      3. I wrote code to put this variable in the configuration directory, go and find the compiler will compile the ( GOPATH user variables )

          C: \ onlineGo # GOPATH specified path

          C: \ onlineGo \ src # src us to write code path

          C: \ onlineGo \ pkg # pkg generated temporary files, library files

          C: \ onlineGo \ bin # go build bin files are generated here

      4. Verify that the path (go env) we modified
          

  2, goland development environment (ide)

      1.  Goland development environment:  https://www.jetbrains.com/go/download/#section=windows

 

Guess you like

Origin www.cnblogs.com/jiaxinzhu/p/12598085.html