Skip to content

Commit

Permalink
Update ci.yml + add changelog.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
t-moe committed Dec 2, 2024
1 parent f3340ea commit e6f004a
Show file tree
Hide file tree
Showing 2 changed files with 50 additions and 4 deletions.
24 changes: 24 additions & 0 deletions .github/workflows/changelog.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
name: Changelog check

on:
pull_request:
# We will not track changes for the following packages/directories.
paths-ignore:
- "/examples/"
# Run on labeled/unlabeled in addition to defaults to detect
# adding/removing skip-changelog labels.
types: [opened, reopened, labeled, unlabeled, synchronize]

jobs:
changelog:
runs-on: ubuntu-latest

steps:
- name: Checkout sources
uses: actions/checkout@v4

- name: Check that changelog updated
uses: dangoslen/changelog-enforcer@v3
with:
skipLabels: "skip-changelog"
missingUpdateErrorMessage: "Please add a changelog entry in the CHANGELOG.md file."
30 changes: 26 additions & 4 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,10 +24,22 @@ jobs:
name: Check
strategy:
matrix:
toolchain:
- stable
- nightly
os:
- ubuntu-latest
#- windows-latest
#- macos-14
log_kind:
- log
- defmt

target_and_example: [
# RISC-V devices:
{ target: "riscv32imac-unknown-none-elf", example: "examples/esp32c6/Cargo.toml" },
]


runs-on: ${{ matrix.os }}

Expand All @@ -38,14 +50,24 @@ jobs:
- name: Checkout sources
uses: actions/checkout@v4

- name: Install riscv32imac-unknown-none-elf target
run: rustup target add riscv32imac-unknown-none-elf
- name: Install target
uses: dtolnay/rust-toolchain@v1
with:
target: ${{ matrix.target_and_example.target}}
toolchain: ${{ matrix.toolchain }}
components: rust-src

- name: Print rustc version
run: rustc --version

- name: Cache Dependencies
uses: Swatinem/[email protected]

- name: Run cargo check
run: cargo check --all-features --locked
- name: Run cargo check for embedded-test
run: cargo check --features ${{matrix.log_kind}} --locked

- name: Run cargo check for example
run: cargo check --no-default-features --features ${{matrix.log_kind}} --manifest-path ${{matrix.target_and_example.example}} --locked

fmt:
name: Rustfmt
Expand Down

0 comments on commit e6f004a

Please sign in to comment.