Skip to content

Retouch env and options. #32

Retouch env and options.

Retouch env and options. #32

name: CI and Release
on:
push:
branches:
- main
tags:
- 'v*'
pull_request:
jobs:
# CI
test:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Set up Go
uses: actions/setup-go@v5
with:
go-version: '1.23'
- name: Install dependencies
run: go mod download
- name: Run tests
run: make test
# Release
release:
if: startsWith(github.ref, 'refs/tags/v')
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Set up Go
uses: actions/setup-go@v5
with:
go-version: '1.23'
- name: Run GoReleaser
uses: goreleaser/goreleaser-action@v5
with:
distribution: goreleaser
version: latest
args: release --clean
env:
GITHUB_TOKEN: ${{ secrets.PERSONAL_GITHUB_TOKEN }}