Skip to content

chore(release): bump version to 0.1.3 #5

chore(release): bump version to 0.1.3

chore(release): bump version to 0.1.3 #5

Workflow file for this run

name: Release
on:
push:
tags:
- 'v*'
permissions:
contents: write
jobs:
build:
name: Build ${{ matrix.target }}
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
include:
- target: linux-x64
os: ubuntu-latest
artifact: uncov-linux-x64
- target: darwin-arm64
os: macos-latest
artifact: uncov-darwin-arm64
- target: darwin-x64
os: macos-latest
artifact: uncov-darwin-x64
- target: windows-x64
os: windows-latest
artifact: uncov-windows-x64.exe
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup Bun
uses: oven-sh/setup-bun@v2
with:
bun-version: latest
- name: Install dependencies
run: bun install --frozen-lockfile
- name: Build binary
run: bun build --compile --target=bun-${{ matrix.target }} --outfile=dist/${{ matrix.artifact }} ./src/cli.ts
- name: Generate checksum
shell: bash
run: |
cd dist
if [[ "${{ matrix.os }}" == "windows-latest" ]]; then
sha256sum ${{ matrix.artifact }} > ${{ matrix.artifact }}.sha256
else
shasum -a 256 ${{ matrix.artifact }} > ${{ matrix.artifact }}.sha256
fi
cat ${{ matrix.artifact }}.sha256
- name: Upload binary artifact
uses: actions/upload-artifact@v4
with:
name: ${{ matrix.artifact }}
path: dist/${{ matrix.artifact }}
if-no-files-found: error
- name: Upload checksum artifact
uses: actions/upload-artifact@v4
with:
name: ${{ matrix.artifact }}.sha256
path: dist/${{ matrix.artifact }}.sha256
if-no-files-found: error
release:
name: Create Release
needs: build
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Download all artifacts
uses: actions/download-artifact@v4
with:
path: artifacts
- name: Prepare release files
run: |
mkdir -p release
# Copy binaries
cp artifacts/uncov-linux-x64/uncov-linux-x64 release/
cp artifacts/uncov-darwin-arm64/uncov-darwin-arm64 release/
cp artifacts/uncov-darwin-x64/uncov-darwin-x64 release/
cp artifacts/uncov-windows-x64.exe/uncov-windows-x64.exe release/
# Copy checksums
cp artifacts/uncov-linux-x64.sha256/uncov-linux-x64.sha256 release/
cp artifacts/uncov-darwin-arm64.sha256/uncov-darwin-arm64.sha256 release/
cp artifacts/uncov-darwin-x64.sha256/uncov-darwin-x64.sha256 release/
cp artifacts/uncov-windows-x64.exe.sha256/uncov-windows-x64.exe.sha256 release/
# Make binaries executable
chmod +x release/uncov-linux-x64
chmod +x release/uncov-darwin-arm64
chmod +x release/uncov-darwin-x64
ls -la release/
- name: Create GitHub Release
uses: softprops/action-gh-release@v2
with:
files: |
release/uncov-linux-x64
release/uncov-linux-x64.sha256
release/uncov-darwin-arm64
release/uncov-darwin-arm64.sha256
release/uncov-darwin-x64
release/uncov-darwin-x64.sha256
release/uncov-windows-x64.exe
release/uncov-windows-x64.exe.sha256
generate_release_notes: true
draft: false
prerelease: false