lil cleanup with default hmm.json stuff #22
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Build & Test hmm-rs (cargo) | |
on: | |
push: | |
branches: [ "main" ] | |
pull_request: | |
branches: [ "main" ] | |
env: | |
CARGO_TERM_COLOR: always | |
jobs: | |
windows: | |
name: windows build/archives (${{ matrix.target }}) | |
if: github.event_name == 'push' | |
runs-on: windows-latest | |
strategy: | |
fail-fast: false | |
matrix: | |
include: | |
- target: x86_64-pc-windows-msvc | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v3 | |
- name: Set up Rust | |
uses: moonrepo/setup-rust@v1 | |
- name: Install target | |
run: rustup target add ${{ matrix.target }} | |
- name: Build | |
run: cargo build --target ${{ matrix.target }} | |
- name: Run tests | |
run: cargo test --target ${{ matrix.target }} | |
- name: Create archive | |
run: | | |
mkdir -p hmm-rs-${{ matrix.target }} | |
cp target/${{ matrix.target }}/debug/hmm-rs.exe ./hmm-rs-${{ matrix.target }}/hmm-rs.exe | |
- name: Upload artifact | |
uses: actions/upload-artifact@v3 | |
with: | |
name: hmm-rs-${{ matrix.target }} | |
path: hmm-rs-${{ matrix.target }} | |
macos: | |
name: macos build/archives (${{ matrix.target }}) | |
if: github.event_name == 'push' | |
runs-on: macos-latest | |
strategy: | |
fail-fast: false | |
matrix: | |
include: | |
- target: x86_64-apple-darwin | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v3 | |
- name: Set up Rust | |
uses: moonrepo/setup-rust@v1 | |
- name: Install target | |
run: rustup target add ${{ matrix.target }} | |
- name: Build | |
run: cargo build --target ${{ matrix.target }} | |
- name: Run tests | |
run: cargo test --target ${{ matrix.target }} | |
- name: Create archive | |
run: | | |
mkdir -p hmm-rs-${{ matrix.target }} | |
cp target/${{ matrix.target }}/debug/hmm-rs ./hmm-rs-${{ matrix.target }}/hmm-rs | |
- name: Upload artifact | |
uses: actions/upload-artifact@v3 | |
with: | |
name: hmm-rs-${{ matrix.target }} | |
path: hmm-rs-${{ matrix.target }} | |
linux: | |
name: linux build/archives (${{ matrix.target }}) | |
if: github.event_name == 'push' | |
runs-on: ubuntu-latest | |
strategy: | |
fail-fast: false | |
matrix: | |
include: | |
- target: x86_64-unknown-linux-gnu | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v3 | |
- name: Set up Rust | |
uses: moonrepo/setup-rust@v1 | |
- name: Install target | |
run: rustup target add ${{ matrix.target }} | |
- name: Build | |
run: cargo build --target ${{ matrix.target }} | |
- name: Run tests | |
run: cargo test --target ${{ matrix.target }} | |
- name: Create archive | |
run: | | |
mkdir -p hmm-rs-${{ matrix.target }} | |
cp target/${{ matrix.target }}/debug/hmm-rs ./hmm-rs-${{ matrix.target }}/hmm-rs | |
- name: Upload artifact | |
uses: actions/upload-artifact@v3 | |
with: | |
name: hmm-rs-${{ matrix.target }} | |
path: hmm-rs-${{ matrix.target }} |