remove editing LOG_WITH_LEVEL for android and iOS #179
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # Trigger CI on PR updates and main branch pushes | |
| # Uses caching and selective path triggers to optimize performance | |
| name: Robrix CI | |
| # Only `main` branch | |
| on: | |
| push: | |
| branches: | |
| - main | |
| paths: | |
| - packaging/** | |
| - resources/** | |
| - src/** | |
| - .github/** | |
| - Cargo.lock | |
| - Cargo.toml | |
| - rust-toolchain.toml | |
| pull_request: | |
| types: [opened, synchronize, reopened, ready_for_review] | |
| branches: | |
| - main | |
| paths: | |
| - packaging/** | |
| - resources/** | |
| - src/** | |
| - .github/** | |
| - Cargo.lock | |
| - Cargo.toml | |
| - rust-toolchain.toml | |
| # Prevent concurrent CI runs and cancel in-progress runs on new pushes | |
| concurrency: | |
| group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }} | |
| cancel-in-progress: true | |
| # Global environment configuration | |
| env: | |
| CARGO_TERM_COLOR: always | |
| CARGO_INCREMENTAL: "0" # Disable incremental compilation in CI | |
| RUST_BACKTRACE: 1 | |
| jobs: | |
| clippy: | |
| if: github.event.pull_request.draft == false | |
| name: clippy | |
| runs-on: macos-14 ## avoids having to install Linux deps | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: actions-rust-lang/setup-rust-toolchain@v1 | |
| with: | |
| rustflags: "" | |
| components: rustfmt, clippy | |
| - uses: Swatinem/rust-cache@v2 | |
| with: | |
| cache-all-crates: "true" | |
| cache-on-failure: "true" | |
| - run: cargo clippy --workspace --all-features | |
| typos: | |
| if: github.event.pull_request.draft == false | |
| name: typos | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Check for typos | |
| uses: crate-ci/typos@master | |
| check_patches: | |
| if: github.event.pull_request.draft == false | |
| name: check patches | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Forbid local path patches in Cargo.toml | |
| # Local `path = ...` in a [patch.*] block is useful for upstream | |
| # debugging but breaks CI and every teammate's checkout when | |
| # accidentally committed. Upstream patches must use `git = ...`. | |
| run: | | |
| awk ' | |
| /^[[:space:]]*#/ {next} | |
| /^[[:space:]]*\[patch/ {in_patch=1; next} | |
| /^[[:space:]]*\[/ {in_patch=0} | |
| in_patch && /path[[:space:]]*=/ { | |
| print "::error file=Cargo.toml,line=" NR "::local path patch found: " $0 | |
| exit 1 | |
| } | |
| ' Cargo.toml |