2020-06-09 16:10:12 +00:00
|
|
|
name: Release
|
|
|
|
|
|
|
|
on:
|
|
|
|
push:
|
|
|
|
tags:
|
|
|
|
- "v*"
|
|
|
|
|
|
|
|
jobs:
|
2020-08-12 20:56:10 +00:00
|
|
|
|
2020-06-09 16:10:12 +00:00
|
|
|
build_linux:
|
|
|
|
name: Build Linux
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
|
|
- uses: actions/checkout@v2
|
|
|
|
- run: |
|
|
|
|
sudo apt-get update
|
|
|
|
sudo apt-get install -y libspeechd-dev
|
|
|
|
cargo build --release
|
2020-07-06 18:35:17 +00:00
|
|
|
rustup target add wasm32-unknown-unknown
|
|
|
|
cargo build --release --target wasm32-unknown-unknown
|
2020-06-09 16:10:12 +00:00
|
|
|
|
|
|
|
build_windows:
|
|
|
|
name: Build Windows
|
|
|
|
runs-on: windows-latest
|
|
|
|
steps:
|
|
|
|
- uses: actions/checkout@v2
|
|
|
|
- run: |
|
|
|
|
choco install -y llvm
|
|
|
|
cargo build --release
|
|
|
|
|
2020-08-12 20:56:10 +00:00
|
|
|
build_macos:
|
|
|
|
name: Build MacOS
|
|
|
|
runs-on: macos-latest
|
|
|
|
steps:
|
|
|
|
- uses: actions/checkout@v2
|
|
|
|
- run: |
|
|
|
|
cargo build --release
|
2020-08-18 20:26:23 +00:00
|
|
|
rustup target add aarch64-apple-ios x86_64-apple-ios
|
|
|
|
cargo install cargo-lipo
|
|
|
|
cargo lipo --release
|
2020-08-12 20:56:10 +00:00
|
|
|
|
2020-06-17 23:00:14 +00:00
|
|
|
publish_winrt_bindings:
|
|
|
|
name: Publish winrt_bindings
|
|
|
|
runs-on: windows-latest
|
2020-08-12 20:56:10 +00:00
|
|
|
needs: [build_windows]
|
2020-06-17 23:00:14 +00:00
|
|
|
env:
|
|
|
|
CARGO_TOKEN: ${{ secrets.CARGO_TOKEN }}
|
|
|
|
steps:
|
|
|
|
- uses: actions/checkout@v2
|
|
|
|
- run: |
|
2020-06-17 23:01:09 +00:00
|
|
|
choco install -y llvm
|
2020-06-17 23:00:14 +00:00
|
|
|
cargo login $CARGO_TOKEN
|
|
|
|
cd winrt_bindings
|
|
|
|
cargo package
|
2020-08-18 20:27:07 +00:00
|
|
|
cargo publish || true
|
2020-06-17 23:00:14 +00:00
|
|
|
|
2020-06-09 16:10:12 +00:00
|
|
|
publish:
|
|
|
|
name: Publish
|
|
|
|
runs-on: ubuntu-latest
|
2020-08-12 20:56:10 +00:00
|
|
|
needs: [build_linux, build_windows, build_macos]
|
2020-06-09 16:10:12 +00:00
|
|
|
env:
|
|
|
|
CARGO_TOKEN: ${{ secrets.CARGO_TOKEN }}
|
|
|
|
steps:
|
|
|
|
- uses: actions/checkout@v2
|
|
|
|
- run: |
|
|
|
|
sudo apt-get update
|
|
|
|
sudo apt-get install -y libspeechd-dev
|
|
|
|
cargo login $CARGO_TOKEN
|
|
|
|
cargo publish
|