Skip to content

Rust

Rust #91

Workflow file for this run

name: Rust
on:
pull_request:
branches: [main]
push:
branches: [main]
schedule:
- cron: 0 0 1 * *
jobs:
build-and-test:
runs-on: ubuntu-latest
steps:
- name: Checkout source
uses: actions/checkout@v2
- name: Build check
uses: actions-rs/cargo@v1
with:
command: check
- name: Tests
uses: actions-rs/cargo@v1
with:
command: test
args: --all-features
linting:
if: ${{ github.event_name == 'pull_request' }}
runs-on: ubuntu-latest
steps:
- name: Checkout source
uses: actions/checkout@v2
- name: format
uses: actions-rs/cargo@v1
with:
command: fmt
args: --all -- --check
- name: clippy
uses: actions-rs/clippy-check@v1
with:
token: ${{ secrets.GITHUB_TOKEN }}
args: -- -D warnings -A clippy::needless-doctest-main