Skip to content

Merge pull request #159 from 0xnim/master #1

Merge pull request #159 from 0xnim/master

Merge pull request #159 from 0xnim/master #1

Workflow file for this run

name: Build Artifacts
on:
push:
branches: [ "master" ]
env:
CARGO_TERM_COLOR: always
jobs:
build:
name: Build project
runs-on: ${{ matrix.os }}
strategy:
matrix:
include:
- os: macos-14
target: aarch64-apple-darwin
executable: target/aarch64-apple-darwin/release/ferrumc
upload_path: target/aarch64-apple-darwin/release/ferrumc
- os: ubuntu-latest
target: x86_64-unknown-linux-gnu
executable: target/x86_64-unknown-linux-gnu/release/ferrumc
upload_path: target/x86_64-unknown-linux-gnu/release/ferrumc
- os: windows-latest
target: x86_64-pc-windows-msvc
executable: target/x86_64-pc-windows-msvc/release/ferrumc.exe
upload_path: target/x86_64-pc-windows-msvc/release/ferrumc.exe
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Cache dependencies
uses: actions/cache@v3
with:
path: |
~/.cargo/registry
~/.cargo/git
target
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }}
restore-keys: |
${{ runner.os }}-cargo-
- name: Install Rust nightly
uses: dtolnay/rust-toolchain@nightly
with:
targets: ${{ matrix.target }}
- name: Build
run: cargo build --release --target ${{ matrix.target }} --verbose
- name: Upload build artifacts
uses: actions/upload-artifact@v3
with:
name: build-artifacts-${{ matrix.os }}
path: ${{ matrix.upload_path }}