diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 3dfa03d..69ef818 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -54,19 +54,21 @@ jobs: go-version-file: go.mod cache: true - - uses: urmzd/sr@v4 + - name: Build release binaries + run: | + mkdir -p bin + for target in linux/amd64 linux/arm64 darwin/amd64 darwin/arm64; do + GOOS=${target%/*} + GOARCH=${target#*/} + output="bin/zigbee-skill-${GOOS}-${GOARCH}" + GOOS=$GOOS GOARCH=$GOARCH CGO_ENABLED=0 go build -o "$output" ./cmd/zigbee-skill + done + + - uses: urmzd/sr@v7 id: sr with: github-token: ${{ steps.app-token.outputs.token }} force: ${{ inputs.force || false }} - build-command: | - mkdir -p bin - for target in linux/amd64 linux/arm64 darwin/amd64 darwin/arm64; do - GOOS=${target%/*} - GOARCH=${target#*/} - output="bin/zigbee-skill-${GOOS}-${GOARCH}" - GOOS=$GOOS GOARCH=$GOARCH CGO_ENABLED=0 go build -o "$output" ./cmd/zigbee-skill - done artifacts: "bin/*" outputs: diff --git a/sr.yaml b/sr.yaml index 746790b..5bc0e16 100644 --- a/sr.yaml +++ b/sr.yaml @@ -1,37 +1,60 @@ -# sr v4 configuration +# sr v7 configuration # Reference: https://github.com/urmzd/sr#configuration +git: + tag_prefix: v + floating_tag: true + commit: - pattern: ^(?P\w+)(?:\((?P[^)]+)\))?(?P!)?:\s+(?P.+) - breaking_section: Breaking Changes - misc_section: Miscellaneous types: - - name: feat - bump: minor - section: Features - - name: fix - bump: patch - section: Bug Fixes - - name: perf - bump: patch - section: Performance - - name: docs - section: Documentation - - name: refactor - bump: patch - section: Refactoring - - name: revert - section: Reverts - - name: chore - - name: ci - - name: test - - name: build - - name: style -release: - branches: - - main - tag_prefix: v - changelog: - file: CHANGELOG.md - version_files: [] - floating_tags: true + minor: + - feat + patch: + - fix + - perf + - refactor + none: + - docs + - revert + - chore + - ci + - test + - build + - style + +changelog: + file: CHANGELOG.md + groups: + - name: breaking + content: + - breaking + - name: features + content: + - feat + - name: bug-fixes + content: + - fix + - name: performance + content: + - perf + - name: refactoring + content: + - refactor + - name: misc + content: + - docs + - revert + - chore + - ci + - test + - build + - style + +channels: + default: stable + branch: main + content: + - name: stable + +packages: + - path: .