Skip to content

Commit

Permalink
Added binary build workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
ko1N committed Mar 4, 2024
1 parent 0ef347b commit f6f7b68
Showing 1 changed file with 38 additions and 0 deletions.
38 changes: 38 additions & 0 deletions .github/workflows/binary-build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
name: Binary build

on:
push:
branch:
- 'main'
- 'stable'

env:
CARGO_TERM_COLOR: always

jobs:

cross-build:
name: Publish binary builds
runs-on: ubuntu-latest
strategy:
matrix:
target: ["x86_64-unknown-linux-gnu", "i686-unknown-linux-gnu", "aarch64-unknown-linux-gnu", "armv7-unknown-linux-gnueabihf", "x86_64-pc-windows-gnu"]
steps:
- uses: actions/checkout@v2
- name: Download renamer
run: curl -sSf https://raw.githubusercontent.com/memflow/memflowup/master/target_rename.sh > target_rename.sh
- name: Build artifacts
uses: actions-rs/cargo@v1
with:
use-cross: true
command: build
args: --release --all-features --workspace --verbose --target ${{ matrix.target }}
- name: Rename and collect artifacts
id: artifacts
run: echo "::set-output name=artifact::$(sh ./target_rename.sh "${{ matrix.target }}" | head -n 1)"
- name: Upload build artifacts
uses: softprops/action-gh-release@v1
with:
tag_name: bin-${{ github.ref_name }}
files: |
${{ steps.artifacts.outputs.artifact }}

0 comments on commit f6f7b68

Please sign in to comment.