k33g GitHub Actions π¦ #2
This file contains 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
name: GitHub Actions Demo | |
run-name: ${{ github.actor }} GitHub Actions π¦ | |
on: [push] | |
jobs: | |
Explore-GitHub-Actions: | |
runs-on: ubuntu-latest | |
env: | |
GO_ARCH: amd64 | |
GO_VERSION: 1.21.3 | |
steps: | |
- name: Install Go | |
run: | | |
sudo apt-get update | |
sudo apt-get install -y curl wget | |
wget https://golang.org/dl/go${GO_VERSION}.linux-${GO_ARCH}.tar.gz | |
tar -xvf go${GO_VERSION}.linux-${GO_ARCH}.tar.gz | |
sudo mv go /usr/local | |
rm go${GO_VERSION}.linux-${GO_ARCH}.tar.gz | |
export PATH="/usr/local/go/bin:${PATH}" | |
export GOPATH="/home/${USER_NAME}/go" | |
export GOROOT="/usr/local/go" | |
- run: go version | |
Go-Deeper-With-GitHub-Actions: | |
runs-on: ubuntu-latest | |
needs: Explore-GitHub-Actions | |
steps: | |
- run: echo "π hello world π" | |
- run: go version |