-
Notifications
You must be signed in to change notification settings - Fork 0
33 lines (33 loc) · 1002 Bytes
/
release-api.yml
File metadata and controls
33 lines (33 loc) · 1002 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
name: Release API
on:
push:
tags:
- api-v*
jobs:
build:
strategy:
matrix:
include:
- runs-on: ubuntu-latest
target: x86_64-unknown-linux-gnu
arch: amd64
- runs-on: ubuntu-24.04-arm
target: aarch64-unknown-linux-gnu
arch: arm64
runs-on: ${{ matrix.runs-on }}
steps:
- uses: actions/checkout@v6
- uses: jdx/mise-action@v4
- uses: Swatinem/rust-cache@v2
- name: Build release binary
run: cargo build --release --target ${{ matrix.target }}
- name: Package
run: |
VERSION=${GITHUB_REF_NAME#api-v}
ARCHIVE="beyond-objects-v${VERSION}-linux-${{ matrix.arch }}.tar.gz"
tar -czf "$ARCHIVE" -C target/${{ matrix.target }}/release beyond-objects
echo "ARCHIVE=$ARCHIVE" >> "$GITHUB_ENV"
- name: Create GitHub release
uses: softprops/action-gh-release@v2
with:
files: ${{ env.ARCHIVE }}