Skip to content

Commit

Permalink
Add CNCLI build to CI
Browse files Browse the repository at this point in the history
  • Loading branch information
mark-stopka committed Sep 23, 2021
1 parent cba7e7b commit e089f8d
Showing 1 changed file with 58 additions and 0 deletions.
58 changes: 58 additions & 0 deletions .github/workflows/build-application-cncli.yaml
@@ -0,0 +1,58 @@
name: Test CNCLI compatibility

on:
push:
release:
types: [created]
pull_request:
branches: [ master ]

env:
CARGO_TERM_COLOR: always

jobs:
build:
name: Build Rust with Cargo
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, macos-latest, macos-11]
rust: [stable, nightly]
runs-on: ${{ matrix.os }}

steps:
- uses: actions/checkout@v2
with:
repository: AndrewWestberg/cncli
- name: Setup Rust
uses: actions-rs/toolchain@v1
with:
toolchain: ${{ matrix.rust }}
override: true
- name: Update CNCLI dependency
run: cargo build --verbose
- name: Build
run: cargo build --verbose
- name: Build examples
run: cargo build --examples --verbose
- name: Run tests
run: cargo test --verbose

build_success:
name: Build Rust with Cargo - All environments
runs-on: ubuntu-latest
needs: build
steps:
- run: echo Done!

publish:
name: Publish tagged release on crates.io
if: github.event_name == 'release' && github.event.action == 'created'
needs:
- build_success
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: katyo/publish-crates@v1
with:
registry-token: ${{ secrets.CARGO_REGISTRY_TOKEN }}

0 comments on commit e089f8d

Please sign in to comment.