Skip to content

refactor (#51)

refactor (#51) #273

Workflow file for this run

name: build and release
env:
GH_ACCESS_TOKEN: ${{ secrets.GH_ACCESS_TOKEN }}
on:
push:
branches:
- main
pull_request:
branches:
- main
jobs:
test-and-build:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest, macos-latest]
arch: [amd64, arm64]
steps:
- name: Checkout code
uses: actions/checkout@v3
- name: Set up Go
uses: actions/setup-go@v3
with:
go-version: '1.23'
- name: Install dependencies
run: go mod tidy
- name: Run tests
run: go test -v -race ./... && go build -race ./...
build-and-release:
runs-on: ubuntu-latest
needs: test-and-build
if: github.ref == 'refs/heads/main' && github.event_name == 'push'
steps:
- name: Checkout code
uses: actions/checkout@v3
- name: Run Auto Tag
uses: phish108/autotag-action@v1.1.55
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
with-v: "true"