name: redbear-ci on: push: # Any version-like release branch (0.3.1, 0.3.2, 0.4.0, 0.5.0, 1.0.0, ...) # keeps triggering CI — including the versioning-machinery checks below — # without editing this file on every bump. Release branches start with a # digit; master is listed explicitly. branches: ["[0-9]*", master] pull_request: jobs: check: runs-on: ubuntu-latest steps: - uses: actions/checkout@v4 with: submodules: recursive - uses: dtolnay/rust-toolchain@nightly with: toolchain: nightly-2026-05-24 - uses: dtolnay/rust-toolchain@nightly with: toolchain: nightly-2026-05-24 components: rustfmt, clippy - name: Check sync-versions compliance run: ./local/scripts/sync-versions.sh --check - name: Install b3sum (versioning machinery + validator) run: sudo apt-get update && sudo apt-get install -y b3sum - name: Versioning machinery unit tests run: ./local/scripts/test-versioning-machinery.sh - name: Vendored-source staleness invalidation test run: ./local/scripts/test-vendored-source-staleness.sh - name: External recipe source-version consistency # Fails if any tar recipe's vendored source/ (or tracked source.tar) # diverges from its declared version — the Qt/KDE class of bug. Mirrors # build-preflight.sh Phase 1.0C so divergence is caught on every push/PR, # not only at build time. run: ./local/scripts/verify-external-source-versions.sh - name: cargo fmt check (redbear-* crates) run: | set -e for f in $(find local/recipes -path "*redbear-*/source/Cargo.toml" -not -path "*/target/*"); do echo "--- cargo fmt --check: $f ---" cargo fmt --manifest-path "$f" -- --check done - name: cargo check (redbear-* crates) run: | set -e for f in $(find local/recipes -path "*redbear-*/source/Cargo.toml" -not -path "*/target/*"); do echo "--- cargo check: $f ---" cargo check --manifest-path "$f" --target x86_64-unknown-redox --locked done continue-on-error: true - name: cargo check host (library-only crates) run: | set -e for f in $(find local/recipes -path "*redbear-hid-core/source/Cargo.toml" -not -path "*/target/*"); do echo "--- cargo check host: $f ---" cargo check --manifest-path "$f" done continue-on-error: true - name: cargo test host (pure-logic crates) run: | set -e for f in $(find local/recipes -path "*redbear-*/source/Cargo.toml" -not -path "*/target/*"); do has_test=$(grep -c '\[\[test\]\]' "$f" 2>/dev/null || true) if [ "$has_test" -gt 0 ]; then echo "--- cargo test: $f ---" cargo test --manifest-path "$f" || echo "NOTE: some tests may require Redox target; continuing" fi done continue-on-error: true