1name: Rust CI 2 3on: 4 push: 5 branches: [ master ] 6 pull_request: 7 branches: [ master ] 8 9env: 10 CARGO_TERM_COLOR: always 11 12jobs: 13 ci: 14 runs-on: ubuntu-latest 15 continue-on-error: ${{ matrix.rust == 'nightly' }} 16 strategy: 17 fail-fast: false 18 matrix: 19 rust: 20 - stable 21 - beta 22 - nightly 23 24 steps: 25 - uses: actions/checkout@v2 26 27 - uses: actions-rs/toolchain@v1 28 with: 29 profile: minimal 30 toolchain: ${{ matrix.rust }} 31 override: true 32 components: rustfmt 33 34 - uses: actions-rs/cargo@v1 35 with: 36 command: build 37 args: --release --all-features -v 38 39 - uses: actions-rs/cargo@v1 40 with: 41 command: test 42 args: --all-features -v 43 44 - uses: actions-rs/cargo@v1 45 with: 46 command: fmt 47 args: --all -- --check 48 49 - name: Security audit 50 uses: actions-rs/audit-check@v1 51 with: 52 token: ${{ secrets.GITHUB_TOKEN }} 53