fix trailing space (#141) #16
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Release | |
on: | |
push: | |
branches: | |
- main | |
paths: | |
- "VERSION" | |
jobs: | |
release: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Setup Go | |
uses: actions/setup-go@v5 | |
with: | |
go-version: "1.21" | |
- name: Build | |
run: go build -v ./... | |
- name: Create Release | |
env: | |
GH_TOKEN: ${{ github.token }} | |
run: | | |
version="v$(cat VERSION)" | |
if gh release view ${version} > /dev/null 2>&1; then | |
echo "Release ${version} already exists. Skipping release creation." | |
else | |
echo "Creating release ${version}." | |
gh release create ${version} --generate-notes | |
fi |