Skip to content

Commit

Permalink
Fix min-versions; add min-version ci check
Browse files Browse the repository at this point in the history
  • Loading branch information
Finomnis committed May 30, 2024
1 parent 1228e2b commit caa092c
Show file tree
Hide file tree
Showing 2 changed files with 29 additions and 7 deletions.
32 changes: 27 additions & 5 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,19 +12,19 @@ jobs:
format:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v4
- run: rustup component add rustfmt
- name: Check library formatting
uses: actions-rs/cargo@v1
with:
command: fmt
args: --verbose --all -- --check

# For each chip, build and lint the main library
clippy:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v4
- uses: actions-rs/toolchain@v1
with:
toolchain: stable
Expand All @@ -42,20 +42,42 @@ jobs:
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v4
- name: Run unit and documentation tests
uses: actions-rs/cargo@v1
with:
command: test
args: --verbose

# Check if dependency versions in Cargo.toml are updated correctly
min-versions:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4

- name: Install nightly toolchain
uses: dtolnay/rust-toolchain@nightly
with:
targets: thumbv7em-none-eabihf

- name: Install cargo-hack
uses: taiki-e/install-action@cargo-hack
- name: Install cargo-minimal-versions
uses: taiki-e/install-action@cargo-minimal-versions

- name: Check with minimal versions
run: cargo minimal-versions check

- name: Run tests with minimal versions
run: cargo minimal-versions test

# Make sure documentation builds, and doclinks are valid
doc:
env:
RUSTDOCFLAGS: -D warnings
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v4
- name: Check documentation and doclinks
uses: actions-rs/cargo@v1
with:
Expand Down
4 changes: 2 additions & 2 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,9 @@ exclude = [

[dependencies]
bitflags = "2"
cortex-m = "0.7"
cortex-m = "0.7.4"
ral-registers = "0.1"
usb-device = "0.3"
usb-device = "0.3.1"

[dependencies.defmt-03]
package = "defmt"
Expand Down

0 comments on commit caa092c

Please sign in to comment.