Skip to content

Commit

Permalink
[programming][go] Update Go
Browse files Browse the repository at this point in the history
to the latest version.

Also explain how to install it on macOS.
  • Loading branch information
LukeShortCloud committed Sep 23, 2024
1 parent 94c4af7 commit de7302a
Showing 1 changed file with 18 additions and 10 deletions.
28 changes: 18 additions & 10 deletions src/programming/go.rst
Original file line number Diff line number Diff line change
Expand Up @@ -32,20 +32,28 @@ Tutorials
Installation
------------

`Download Go <https://golang.org/dl/>`__, extract it, add the new Go binary $PATH and load it. [11]
`Download Go <https://golang.org/dl/>`__, extract it, add the new Go binary $PATH, and load it. [11]

.. code-block:: sh
- Linux

$ export GO_VERSION="1.19.2"
$ export GO_OS="linux"
$ export GO_ARCH="amd64"
.. code-block:: sh
.. code-block:: sh
$ export GO_VERSION="1.23.1"
$ export GO_OS="linux"
$ export GO_ARCH="amd64"
.. code-block:: sh
$ wget https://dl.google.com/go/go${GO_VERSION}.${GO_OS}-${GO_ARCH}.tar.gz
$ tar -C /usr/local -x -z -f go${GO_VERSION}.${GO_OS}-${GO_ARCH}.tar.gz
$ echo "PATH=$PATH:/usr/local/go/bin" >> ~/.profile
$ . ~/.profile
- macOS

.. code-block:: sh
$ wget https://dl.google.com/go/go${GO_VERSION}.${GO_OS}-${GO_ARCH}.tar.gz
$ tar -C /usr/local -x -z -f go${GO_VERSION}.${GO_OS}-${GO_ARCH}.tar.gz
$ echo "PATH=$PATH:/usr/local/go/bin" >> ~/.profile
$ . ~/.profile
$ brew install go
Release Cycle
-------------
Expand Down

0 comments on commit de7302a

Please sign in to comment.