Created
April 2, 2025 17:35
-
-
Save senapk/62f85712098517a23a2fc72fa6824ba3 to your computer and use it in GitHub Desktop.
script para instalar o golang no codespace
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# para desinstalar o go caso tenha baixado anteriormente | |
sudo rm -rf /usr/local/go | |
# para desisntalar o go caso tenha baixado via apt | |
sudo apt remove --purge golang-go -y | |
sudo apt autoremove -y | |
# para instalar a versão mais nova | |
wget https://go.dev/dl/go1.24.2.linux-amd64.tar.gz | |
sudo tar -C /usr/local -xzf go1.24.2.linux-amd64.tar.gz | |
echo 'export PATH=$PATH:/usr/local/go/bin' >> ~/.profile | |
source ~/.profile |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment