Skip to content

Instantly share code, notes, and snippets.

@yonderbread
Created April 29, 2021 20:15
Show Gist options
  • Save yonderbread/3a6ec848232ca5fb4104abe835b2a61f to your computer and use it in GitHub Desktop.
Save yonderbread/3a6ec848232ca5fb4104abe835b2a61f to your computer and use it in GitHub Desktop.
a little script to install golang on my raspberry pi
export GOLANG_URL="https://golang.org/dl"
export GOLANG_FILENAME="go1.16.3.linux-armv6l.tar.gz"
sudo apt update && sudo apt install wget -y
wget "$GOLANG_URL/$GOLANG_FILENAME"
sudo rm -rf /usr/local/go && tar -C /usr/local -xzf $GOLANG_FILENAME
sudo echo "export PATH=$PATH:/usr/local/go/bin" >> /etc/profile
source /etc/profile
rm -rf $GOLANG_FILENAME
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment