1name: CI 2 3on: 4 push: 5 pull_request: 6 schedule: [cron: "40 1 * * *"] 7 8permissions: 9 contents: read 10 11env: 12 RUSTFLAGS: -Dwarnings 13 14jobs: 15 test: 16 name: Rust ${{matrix.rust}} 17 runs-on: ubuntu-latest 18 strategy: 19 fail-fast: false 20 matrix: 21 rust: [nightly, beta, stable, 1.31.0] 22 timeout-minutes: 45 23 steps: 24 - uses: actions/checkout@v3 25 - uses: dtolnay/rust-toolchain@master 26 with: 27 toolchain: ${{matrix.rust}} 28 - run: cargo test 29 30 clippy: 31 name: Clippy 32 runs-on: ubuntu-latest 33 if: github.event_name != 'pull_request' 34 timeout-minutes: 45 35 steps: 36 - uses: actions/checkout@v3 37 - uses: dtolnay/rust-toolchain@clippy 38 - run: cargo clippy -- -Dclippy::all -Dclippy::pedantic 39 40 outdated: 41 name: Outdated 42 runs-on: ubuntu-latest 43 if: github.event_name != 'pull_request' 44 timeout-minutes: 45 45 steps: 46 - uses: actions/checkout@v3 47 - uses: dtolnay/install@cargo-outdated 48 - run: cargo outdated --workspace --exit-code 1 49