This repository has been archived by the owner on Nov 22, 2023. It is now read-only.
cargo udeps #42
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: cargo udeps | |
on: | |
schedule: | |
# Every week at 12 p.m. on Sundays | |
- cron: "0 12 * * 0" | |
env: | |
CARGO_TERM_COLOR: always | |
CARGO_REGISTRIES_CRATES_IO_PROTOCOL: sparse | |
jobs: | |
check-unused-dependencies: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: actions-rs/toolchain@v1 | |
with: | |
# Nightly is needed for udeps | |
toolchain: nightly | |
override: true | |
- name: Cache Cargo build files | |
uses: Leafwing-Studios/cargo-cache@v1 | |
# We don't --force install to reduce CI times (drastically) | |
# We fix the version so that it overwrites when we specify a new one | |
# We need to remember to update the version from time to time | |
- name: Installs cargo-udeps | |
run: cargo install [email protected] | |
# Cargo gives an error if it's already installed | |
continue-on-error: true | |
- name: Install alsa and udev | |
run: sudo apt-get update; sudo apt-get install --no-install-recommends libasound2-dev libudev-dev | |
- name: Check for unused dependencies | |
run: cargo udeps |