Skip to content

refactor: move to workspace dependencies (#569) #257

refactor: move to workspace dependencies (#569)

refactor: move to workspace dependencies (#569) #257

Workflow file for this run

name: release
on:
push:
branches:
- main
- release/*
env:
RUSTFLAGS: -Dwarnings
jobs:
artifacts:
name: Artifacts
runs-on: ${{ matrix.config.os }}
strategy:
fail-fast: false
matrix:
config:
- os: "ubuntu-latest"
dir: linux-x86_64
artifacts: "mun libmun_runtime.so"
RUSTFLAGS: "-Dwarnings"
- os: "windows-latest"
dir: windows-x86_64
artifacts: "mun.exe mun_runtime.dll mun_runtime.dll.lib"
RUSTFLAGS: "-Dwarnings -Ctarget-feature=+crt-static"
- os: "macOS-latest"
dir: macos-x86_64
artifacts: "mun libmun_runtime.dylib"
RUSTFLAGS: "-Dwarnings"
steps:
- uses: actions/checkout@v4
with:
submodules: true
- name: Install toolchain
uses: actions-rs/toolchain@v1
with:
profile: minimal
override: true
- name: Install LLVM
uses: ./.github/actions/install-llvm
- name: Cargo build
uses: actions-rs/cargo@v1
env:
RUSTFLAGS: ${{ matrix.config.RUSTFLAGS }}
with:
command: build
args: --release
- run: mkdir -p ${{ matrix.config.dir }}
- name: Move artifacts
env:
ARTIFACTS: ${{ matrix.config.artifacts }}
OUT_DIR: ${{ matrix.config.dir }}
run: |
import os
artifacts = os.environ['ARTIFACTS'].split()
for artifact in artifacts:
src = "target/release/%s" % artifact
dst = os.environ['OUT_DIR'] + "/" + artifact
os.rename(src, dst)
shell: python
- uses: actions/upload-artifact@master
with:
name: ${{ matrix.config.dir }}
path: ${{ matrix.config.dir }}