Skip to content

Bump to 0.2.5

Bump to 0.2.5 #19

---
name: Release
on:
push:
tags:
- 'v*' # Push events to matching v*, i.e., v1.0
jobs:
release:
name: Create release
runs-on: ${{ matrix.os }}
strategy:
matrix:
include:
- build: linux
os: ubuntu-latest
target: x86_64-unknown-linux-gnu
- build: linux
os: ubuntu-latest
target: x86_64-unknown-linux-musl
- build: macos
os: macos-latest
target: x86_64-apple-darwin
steps:
- uses: actions/checkout@v4
- uses: actions/cache@v4
with:
path: |
~/.cargo/bin/
~/.cargo/registry/index/
~/.cargo/registry/cache/
~/.cargo/git/db/
target/
key: ${{ runner.os }}-${{ matrix.target }}-cargo-${{ hashFiles('**/Cargo.lock') }}
- uses: dtolnay/rust-toolchain@stable
with:
targets: ${{ matrix.target }}
- name: Build
uses: actions-rs/cargo@v1
with:
use-cross: true
command: build
args: --target ${{ matrix.target }} --release
- name: Build archive
run: |
binary_name="fltn"
archive_name="$binary_name-${{ github.ref_name }}-${{ matrix.target }}.tar.gz"
tar -C "target/${{ matrix.target }}/release" \
-czf "$archive_name" "$binary_name"
echo "ASSET=$archive_name" >> $GITHUB_ENV
- name: Release
uses: softprops/action-gh-release@v2
with:
files: "${{ env.ASSET }}"