From 765616a67e1f5712361a31221fc1afdb9141c48f Mon Sep 17 00:00:00 2001 From: Owen Ou Date: Fri, 29 Sep 2023 21:30:28 -0700 Subject: [PATCH] Update GH Actions --- .github/workflows/build.yml | 27 ++++++++++++--------------- .github/workflows/release.yaml | 13 +++++++------ 2 files changed, 19 insertions(+), 21 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 6aebe99e0..63e25564a 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -2,7 +2,6 @@ name: Build on: push: - repository_dispatch: pull_request: jobs: @@ -13,13 +12,12 @@ jobs: matrix: os: [ macos-latest, ubuntu-latest ] steps: - - name: Set up Go 1.x - uses: actions/setup-go@v2 + - name: Set up Go + uses: actions/setup-go@v4 with: - go-version: ^1.19 - id: go - - name: Check out code into the Go module directory - uses: actions/checkout@v2 + go-version-file: go.mod + check-latest: true + - uses: actions/checkout@v3 - name: Compile run: make install test: @@ -29,13 +27,12 @@ jobs: matrix: os: [ macos-latest, ubuntu-latest ] steps: - - name: Set up Go 1.x - uses: actions/setup-go@v2 + - name: Set up Go + uses: actions/setup-go@v4 with: - go-version: ^1.19 - id: go - - name: Check out code into the Go module directory - uses: actions/checkout@v2 + go-version-file: go.mod + check-latest: true + - uses: actions/checkout@v3 - name: Test run: make test env: @@ -46,7 +43,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Check out code into the Go module directory - uses: actions/checkout@v2 + uses: actions/checkout@v3 - name: Vet run: make vet docker: @@ -54,6 +51,6 @@ jobs: runs-on: ubuntu-latest steps: - name: Check out code into the Go module directory - uses: actions/checkout@v2 + uses: actions/checkout@v3 - name: Docker run: make docker_build diff --git a/.github/workflows/release.yaml b/.github/workflows/release.yaml index 6c7bc5bb1..a22007604 100644 --- a/.github/workflows/release.yaml +++ b/.github/workflows/release.yaml @@ -9,15 +9,16 @@ jobs: if: "!contains(github.ref, '-')" # skip prereleases steps: - name: Checkout - uses: actions/checkout@v2 + uses: actions/checkout@v3 - name: Set up Go - uses: actions/setup-go@v2 + uses: actions/setup-go@v4 with: - go-version: 1.19 + go-version-file: go.mod + check-latest: true - name: Run GoReleaser - uses: goreleaser/goreleaser-action@v2 + uses: goreleaser/goreleaser-action@v4 with: - version: latest + version: v1.21.2 args: release --rm-dist env: GITHUB_TOKEN: ${{ secrets.GH_TOKEN }} @@ -32,7 +33,7 @@ jobs: runs-on: ubuntu-latest needs: [release] steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v3 - uses: superfly/flyctl-actions/setup-flyctl@master - run: flyctl deploy --remote-only env: