Skip to content

update github action version #49

update github action version

update github action version #49

Workflow file for this run

name: release
on:
push:
tags:
- '*'
jobs:
goreleaser:
runs-on: ubuntu-latest
steps:
-
name: Checkout
uses: actions/checkout@v4
with:
fetch-depth: 0
-
name: Set up Go
uses: actions/setup-go@v5
with:
go-version: '1.22'
-
name: Set Build Info
id: "info"
run: |
echo "::set-output name=commit::$(git rev-parse --short HEAD)"
echo "::set-output name=buildtime::$(TZ='Asia/Shanghai' date '+%Y/%m/%d-%H:%M:%S %Z')"
echo "goversion=$(go version | awk '{print $3}')" >> "$GITHUB_OUTPUT"
-
name: Run GoReleaser
uses: goreleaser/goreleaser-action@v6
with:
version: latest
args: release --clean
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
COMMIT: ${{ steps.info.outputs.commit }}
BUILD_TIME: ${{ steps.info.outputs.buildtime }}
GOVERSION: ${{ steps.info.outputs.goversion }}