name: CI # Formatting, lints and tests on every push to master and every pull request. on: push: branches: [master] pull_request: jobs: check: runs-on: ubuntu-22.04 steps: - uses: actions/checkout@v6 - uses: dtolnay/rust-toolchain@stable with: components: clippy, rustfmt targets: aarch64-linux-android - run: sudo apt-get update && sudo apt-get install -y pkg-config libwayland-dev libxkbcommon-dev - run: cargo fmt --all -- --check - run: cargo clippy --workspace --all-targets --locked -- -D warnings # The core also goes into the Android app (docs/android.md). A check needs no NDK. - run: cargo clippy -p budctl-core --target aarch64-linux-android --locked -- -D warnings - run: cargo test --workspace --locked - run: sh -n install.sh # The Android app: its Rust library (debug, for the phone and the emulator), the app and its JVM # tests. The manifest check (no INTERNET) runs with the build. android: runs-on: ubuntu-24.04 steps: - uses: actions/checkout@v6 - uses: actions/setup-java@v6 with: distribution: temurin java-version: 21 - uses: dtolnay/rust-toolchain@stable with: targets: aarch64-linux-android, x86_64-linux-android - run: cargo install cargo-ndk --locked - name: Android SDK packages run: yes | "$ANDROID_HOME/cmdline-tools/latest/bin/sdkmanager" --install "ndk;30.0.16248370" "platforms;android-37.0" "build-tools;36.0.0" > /dev/null - run: ./gradlew --no-daemon assembleDebug testDebugUnitTest working-directory: android