Skip to content

Workflow file for this run

# Build binaries and upload them to GitHub
on:
release:
types: [published]
jobs:
release:
name: release ${{ matrix.target }}
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
include:
- target: x86_64-unknown-linux-musl
archive: tar.gz tar.xz
- target: x86_64-pc-windows-gnu
archive: zip
- target: x86_64-apple-darwin
archive: zip
steps:
- uses: actions/checkout@master
- name: Build NetsBlox CLI
uses: rust-build/rust-build.action@v1.4.0
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
RUSTTARGET: ${{ matrix.target }}
ARCHIVE_TYPES: ${{ matrix.archive }}
SRC_DIR: crates/cli
TOOLCHAIN_VERSION: 1.83
ARCHIVE_NAME: netsblox_cli_${{ github.event.release.name }}_${{ matrix.target }}
- name: Build NetsBlox Cloud
uses: rust-build/rust-build.action@v1.4.0
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
RUSTTARGET: ${{ matrix.target }}
ARCHIVE_TYPES: ${{ matrix.archive }}
TOOLCHAIN_VERSION: 1.83
SRC_DIR: crates/cloud
ARCHIVE_NAME: netsblox_cloud_${{ github.event.release.name }}_${{ matrix.target }}
- name: Publish (to crates.io)
if: matrix.target == 'x86_64-unknown-linux-musl'
env:
CARGO_REGISTRY_TOKEN: ${{ secrets.CARGO_REGISTRY_TOKEN }}
run: |
cargo publish -p netsblox-api-common
cargo publish -p netsblox-api
cargo publish -p netsblox-cli
cargo publish -p netsblox-cloud-common
cargo publish -p netsblox-cloud