diff --git a/.github/workflows/build-all.yaml b/.github/workflows/release.yaml similarity index 61% rename from .github/workflows/build-all.yaml rename to .github/workflows/release.yaml index 8653cbf..bd59161 100644 --- a/.github/workflows/build-all.yaml +++ b/.github/workflows/release.yaml @@ -1,31 +1,37 @@ -name: build +name: release -on: push +on: + create: + tags: + - v* permissions: contents: write jobs: - build: + release: + if: startsWith(github.ref, 'refs/tags/v') runs-on: ubuntu-latest steps: - name: Checkout uses: actions/checkout@v4 with: fetch-depth: 0 # To use `git describe --tags` + - name: Setup Go uses: actions/setup-go@v5 with: - go-version: '1.22' + go-version: "1.22" + - name: Setup Task uses: arduino/setup-task@v2 - - name: Build all - run: task build:dist:all + + - name: Build and package + run: task build-and-package + - name: Release uses: softprops/action-gh-release@v2 - if: startsWith(github.ref, 'refs/tags/') with: files: | - README.md - LICENSE - dist/**/* + dist/**/*.tar.gz + dist/**/*.tar.gz.sha256sum