Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: update GitHub Actions versions in build and release workflows #481

Merged
merged 1 commit into from
Oct 19, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 9 additions & 9 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ name: build
on:
push:
pull_request:
branches: [ master ]
branches: [master]

jobs:
build:
Expand All @@ -14,20 +14,20 @@ jobs:
runs-on: ${{ matrix.os }}
steps:
- name: check out code
uses: actions/checkout@v2
uses: actions/checkout@v4
- name: setup Go 1.21
id: go
uses: actions/setup-go@v2
uses: actions/setup-go@v4
with:
go-version: ^1.21
- name: build
run: make build
- name: install dependency
run: if [ $(uname) == "Darwin" ]; then brew install gnu-sed ;fi
run: if [ $(uname) == "Darwin" ]; then brew install gnu-sed ;fi
- name: run Unit tests.
run: go install github.com/go-delve/delve/cmd/dlv@latest && go test ./... -v -covermode=count -coverprofile=coverage.txt
- name: upload Coverage report to CodeCov
uses: codecov/codecov-action@v2
uses: codecov/codecov-action@v3
with:
token: ${{ secrets.CODECOV_TOKEN }}
file: ./coverage.txt
Expand All @@ -39,17 +39,17 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Set up QEMU
uses: docker/setup-qemu-action@v1
uses: docker/setup-qemu-action@v3
- name: set up Docker Buildx
uses: docker/setup-buildx-action@v1
uses: docker/setup-buildx-action@v3
- name: login to DockerHub
uses: docker/login-action@v1
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
- name: build and push
id: docker_build
uses: docker/build-push-action@v2
uses: docker/build-push-action@v5
with:
push: true
platforms: linux/amd64,linux/arm64
Expand Down
10 changes: 5 additions & 5 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ name: release
on:
push:
pull_request:
branches: [ master ]
branches: [master]

jobs:
release:
Expand Down Expand Up @@ -33,17 +33,17 @@ jobs:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

- name: Set up QEMU
uses: docker/setup-qemu-action@v1
uses: docker/setup-qemu-action@v3
- name: set up Docker Buildx
uses: docker/setup-buildx-action@v1
uses: docker/setup-buildx-action@v3
- name: login to DockerHub
uses: docker/login-action@v1
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
- name: push to docker hub
id: docker_build
uses: docker/build-push-action@v2
uses: docker/build-push-action@v5
with:
push: true
platforms: linux/amd64,linux/arm64
Expand Down
7 changes: 4 additions & 3 deletions .github/workflows/smoke_test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,17 +2,18 @@ name: smoke_test

on:
push:
pull_request:

jobs:
smoke_test_ubuntu:
uses: cosmtrek/air/.github/workflows/smoke_test_reuse_job.yml@add_smoke_test
with:
with:
run_on: ubuntu-latest
smoke_test_macos:
uses: cosmtrek/air/.github/workflows/smoke_test_reuse_job.yml@add_smoke_test
with:
with:
run_on: macos-latest
smoke_test_windows:
uses: cosmtrek/air/.github/workflows/smoke_test_window_reust_job.yml@fix_window_arg_bug
with:
with:
run_on: windows-latest
2 changes: 1 addition & 1 deletion .github/workflows/smoke_test_reuse_job.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ jobs:
- name: check rebuild
id: check_rebuild
working-directory: ./smoke_test/check_rebuild
run: |
run: |
nohup air > nohup.out 2> nohup.err < /dev/null &
sleep 15
echo "" >> main.go
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/smoke_test_window_reust_job.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,8 +31,8 @@ jobs:
- name: check rebuild
id: check_rebuild
working-directory: ./smoke_test
run: |
python smoke_test.py
run: |
python smoke_test.py
- uses: nick-invision/assert-action@v1
with:
expected: "PASS"
Expand Down
Loading