diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 35c0bffa4e..1493c3f66a 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -22,10 +22,11 @@ jobs: uses: actions/checkout@v3 - name: Fail on warnings + working-directory: ./rtic run: sed -i 's,//deny_warnings_placeholder_for_ci,#![deny(warnings)],' src/lib.rs macros/src/lib.rs - - name: cargo fmt --check + working-directory: ./rtic run: cargo fmt --all -- --check # Compilation check @@ -45,20 +46,24 @@ jobs: uses: actions/checkout@v3 - name: Install Rust ${{ matrix.toolchain }} + working-directory: ./rtic run: | rustup set profile minimal rustup override set ${{ matrix.toolchain }} - name: Configure Rust target (${{ matrix.target }}) + working-directory: ./rtic run: rustup target add ${{ matrix.target }} - name: Fail on warnings + working-directory: ./rtic run: sed -i 's,//deny_warnings_placeholder_for_ci,#![deny(warnings)],' src/lib.rs macros/src/lib.rs - name: Cache Dependencies uses: Swatinem/rust-cache@v2 - name: cargo check + working-directory: ./rtic run: cargo check --target=${{ matrix.target }} # Clippy @@ -70,15 +75,18 @@ jobs: uses: actions/checkout@v3 - name: Fail on warnings + working-directory: ./rtic run: sed -i 's,//deny_warnings_placeholder_for_ci,#![deny(warnings)],' src/lib.rs macros/src/lib.rs - name: Add Rust component clippy + working-directory: ./rtic run: rustup component add clippy - name: Cache Dependencies uses: Swatinem/rust-cache@v2 - name: cargo clippy + working-directory: ./rtic run: cargo clippy # Verify all examples, checks @@ -113,6 +121,7 @@ jobs: uses: Swatinem/rust-cache@v2 - name: Check the examples + working-directory: ./rtic run: cargo check --examples --target=${{ matrix.target }} # Verify the example output with run-pass tests @@ -154,9 +163,11 @@ jobs: sudo apt install -y qemu-system-arm - name: Fail on warnings + working-directory: ./rtic run: sed -i 's,//deny_warnings_placeholder_for_ci,#![deny(warnings)],' src/lib.rs macros/src/lib.rs - name: Run-pass tests + working-directory: ./rtic run: cargo xtask --target ${{ matrix.target }} # Check the correctness of macros/ crate @@ -185,9 +196,11 @@ jobs: uses: Swatinem/rust-cache@v2 - name: Fail on warnings + working-directory: ./rtic run: sed -i 's,//deny_warnings_placeholder_for_ci,#![deny(warnings)],' src/lib.rs macros/src/lib.rs - name: cargo check + working-directory: ./rtic run: cargo check --manifest-path macros/Cargo.toml --target=${{ matrix.target }} # Run the macros test-suite @@ -202,9 +215,11 @@ jobs: uses: Swatinem/rust-cache@v2 - name: Fail on warnings + working-directory: ./rtic run: sed -i 's,//deny_warnings_placeholder_for_ci,#![deny(warnings)],' src/lib.rs macros/src/lib.rs - name: cargo check + working-directory: ./rtic run: cargo test --manifest-path macros/Cargo.toml # Run test suite @@ -219,9 +234,11 @@ jobs: uses: Swatinem/rust-cache@v2 - name: Fail on warnings + working-directory: ./rtic run: sed -i 's,//deny_warnings_placeholder_for_ci,#![deny(warnings)],' src/lib.rs macros/src/lib.rs - name: Run cargo test + working-directory: ./rtic run: cargo test --test tests # # Build documentation, check links diff --git a/.github/workflows/changelog.yml b/.github/workflows/changelog.yml index 74b821dabc..6e23a7a051 100644 --- a/.github/workflows/changelog.yml +++ b/.github/workflows/changelog.yml @@ -18,10 +18,28 @@ jobs: - name: Checkout sources uses: actions/checkout@v3 - - name: Check that changelog updated + - name: Check that changelog updated (rtic) uses: dangoslen/changelog-enforcer@v3 with: - changeLogPath: CHANGELOG.md + changeLogPath: ./rtic/CHANGELOG.md + skipLabels: 'needs-changelog, skip-changelog' + missingUpdateErrorMessage: 'Please add a changelog entry in the CHANGELOG.md file.' + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + + - name: Check that changelog updated (rtic-timer) + uses: dangoslen/changelog-enforcer@v3 + with: + changeLogPath: ./rtic-timer/CHANGELOG.md + skipLabels: 'needs-changelog, skip-changelog' + missingUpdateErrorMessage: 'Please add a changelog entry in the CHANGELOG.md file.' + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + + - name: Check that changelog updated (rtic-monotonics) + uses: dangoslen/changelog-enforcer@v3 + with: + changeLogPath: ./rtic-monotonics/CHANGELOG.md skipLabels: 'needs-changelog, skip-changelog' missingUpdateErrorMessage: 'Please add a changelog entry in the CHANGELOG.md file.' env: diff --git a/rtic-monotonics/CHANGELOG.md b/rtic-monotonics/CHANGELOG.md new file mode 100644 index 0000000000..e69de29bb2 diff --git a/rtic-timer/CHANGELOG.md b/rtic-timer/CHANGELOG.md new file mode 100644 index 0000000000..e69de29bb2 diff --git a/rtic/Cargo.toml b/rtic/Cargo.toml index c22d02372f..6eb691df6e 100644 --- a/rtic/Cargo.toml +++ b/rtic/Cargo.toml @@ -51,7 +51,7 @@ codegen-units = 1 lto = true [workspace] -members = ["macros", "xtask", "rtic-timer"] +members = ["macros", "xtask"] # do not optimize proc-macro deps or build scripts [profile.dev.build-override]