From e82a5db8266387167b92258ffe88bd8f2d32cd73 Mon Sep 17 00:00:00 2001 From: MJSM Date: Wed, 22 Feb 2023 11:21:47 -0300 Subject: [PATCH] update(workflows): add win, linux and macos artifacts --- .github/workflows/go-linux.yml | 38 +++++++++++++++++++++++++++ .github/workflows/go-mac.yml | 38 +++++++++++++++++++++++++++ .github/workflows/go.yml | 47 +++++++++++++++++----------------- 3 files changed, 99 insertions(+), 24 deletions(-) create mode 100644 .github/workflows/go-linux.yml create mode 100644 .github/workflows/go-mac.yml diff --git a/.github/workflows/go-linux.yml b/.github/workflows/go-linux.yml new file mode 100644 index 0000000..1ea3356 --- /dev/null +++ b/.github/workflows/go-linux.yml @@ -0,0 +1,38 @@ +# This workflow will build a golang project +# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-go + +name: Go Linux + +on: + push: + branches: ["master"] + pull_request: + branches: ["master"] + workflow_dispatch: + +jobs: + build: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3 + + - name: Set up Go + uses: actions/setup-go@v3 + with: + go-version: 1.19 + + - name: Install dependencies + run: go get . + + - name: Build + run: go build -v + + - name: Test + run: go test -v + + - name: Upload a Build Artifact + uses: actions/upload-artifact@v3.1.2 + with: + name: tweego-linux + path: ./tweego + # The desired behavior if no files are found using the provided path. diff --git a/.github/workflows/go-mac.yml b/.github/workflows/go-mac.yml new file mode 100644 index 0000000..c29daa4 --- /dev/null +++ b/.github/workflows/go-mac.yml @@ -0,0 +1,38 @@ +# This workflow will build a golang project +# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-go + +name: Go Linux + +on: + push: + branches: ["master"] + pull_request: + branches: ["master"] + workflow_dispatch: + +jobs: + build: + runs-on: macos-latest + steps: + - uses: actions/checkout@v3 + + - name: Set up Go + uses: actions/setup-go@v3 + with: + go-version: 1.19 + + - name: Install dependencies + run: go get . + + - name: Build + run: go build -v + + - name: Test + run: go test -v + + - name: Upload a Build Artifact + uses: actions/upload-artifact@v3.1.2 + with: + name: tweego-macos + path: ./tweego + # The desired behavior if no files are found using the provided path. diff --git a/.github/workflows/go.yml b/.github/workflows/go.yml index fd5ebc2..46fae1f 100644 --- a/.github/workflows/go.yml +++ b/.github/workflows/go.yml @@ -1,39 +1,38 @@ # This workflow will build a golang project # For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-go -name: Go Ubuntu +name: Go Windows on: push: - branches: [ "master" ] + branches: ["master"] pull_request: - branches: [ "master" ] + branches: ["master"] workflow_dispatch: jobs: - build: - runs-on: ubuntu-latest + runs-on: windows-latest steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v3 - - name: Set up Go - uses: actions/setup-go@v3 - with: - go-version: 1.19 - - - name: Install dependencies - run: go get . + - name: Set up Go + uses: actions/setup-go@v3 + with: + go-version: 1.19 - - name: Build - run: go build -v + - name: Install dependencies + run: go get . - - name: Test - run: go test -v - - - name: Upload a Build Artifact - uses: actions/upload-artifact@v3.1.2 - with: - name: Tweego - path: ./tweego - # The desired behavior if no files are found using the provided path. + - name: Build + run: go build -v + + - name: Test + run: go test -v + + - name: Upload a Build Artifact + uses: actions/upload-artifact@v3.1.2 + with: + name: tweego-windows + path: ./tweego.exe + # The desired behavior if no files are found using the provided path.