Skip to content

Commit

Permalink
use cross for release
Browse files Browse the repository at this point in the history
  • Loading branch information
JanKaul committed Nov 13, 2024
1 parent 896897e commit f48ea77
Showing 1 changed file with 32 additions and 20 deletions.
52 changes: 32 additions & 20 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,28 +5,40 @@ on:
- "v*"
jobs:
release:
runs-on: ${{ matrix.os }}
name: Release - ${{ matrix.platform.os-name }}
strategy:
matrix:
os: [ubuntu-latest, windows-latest, macos-latest]
platform:
- os-name: Linux-x86_64
runs-on: ubuntu-20.04
target: x86_64-unknown-linux-gnu

- os-name: Windows-x86_64
runs-on: windows-latest
target: x86_64-pc-windows-msvc

- os-name: macOS-x86_64
runs-on: macOS-latest
target: x86_64-apple-darwin
binary:
- name: frostbow
- name: frostbow-sql
- name: frostbow-glue

runs-on: ${{ matrix.platform.runs-on }}
steps:
- uses: actions/checkout@v4
- name: test build rust project
uses: lxl66566/rust-simple-release@main
- name: Checkout
uses: actions/checkout@v3
- name: Build binary
uses: houseabsolute/actions-rust-cross@v0
with:
targets: x86_64-pc-windows-msvc, x86_64-unknown-linux-gnu, x86_64-apple-darwin
token: ${{ secrets.GITHUB_TOKEN }}
package: frostbow
release-sql:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest, windows-latest, macos-latest]
steps:
- uses: actions/checkout@v4
- name: test build rust project
uses: lxl66566/rust-simple-release@main
command: ${{ matrix.platform.command }}
target: ${{ matrix.platform.target }}
args: "--locked --release"
strip: true
working-directory: ${{ matrix.binary.name }}
- name: Publish artifacts and release
uses: houseabsolute/actions-rust-release@v0
with:
targets: x86_64-pc-windows-msvc, x86_64-unknown-linux-gnu, x86_64-apple-darwin
token: ${{ secrets.GITHUB_TOKEN }}
package: frostbow-sql
executable-name: ${{ matrix.binary.name }}
target: ${{ matrix.platform.target }}

0 comments on commit f48ea77

Please sign in to comment.