Repository navigation
Add commit check to CI #263
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
| --- | |
| name: loopdev-3 ci | |
| on: | |
| push: | |
| pull_request: | |
| workflow_dispatch: | |
| jobs: | |
| check: | |
| name: Check | |
| runs-on: ubuntu-latest | |
| strategy: | |
| matrix: | |
| target: | |
| - aarch64-linux-android | |
| - aarch64-unknown-linux-gnu | |
| - aarch64-unknown-linux-musl | |
| - x86_64-unknown-linux-gnu | |
| - x86_64-unknown-linux-musl | |
| steps: | |
| - name: Checkout sources | |
| uses: actions/checkout@v6 | |
| with: | |
| persist-credentials: false | |
| - name: Install stable toolchain | |
| uses: actions-rs/toolchain@v1 | |
| with: | |
| profile: minimal | |
| toolchain: stable | |
| target: ${{ matrix.target }} | |
| override: true | |
| - name: Cross | |
| run: cargo install --git https://github.com/cross-rs/cross.git --rev bb3df1b cross | |
| - name: Run cargo check | |
| uses: actions-rs/cargo@v1 | |
| with: | |
| use-cross: true | |
| command: check | |
| args: --target=${{ matrix.target }} | |
| lints: | |
| name: Lints | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout sources | |
| uses: actions/checkout@v6 | |
| with: | |
| persist-credentials: false | |
| - name: Install stable toolchain | |
| uses: actions-rust-lang/setup-rust-toolchain@v1 | |
| with: | |
| profile: minimal | |
| components: rustfmt, clippy | |
| - name: Install bindgen dependencies | |
| run: sudo apt-get install llvm-dev libclang-dev clang | |
| - name: Run cargo fmt | |
| run: make -f Makefile fmt-ci | |
| - name: Run cargo clippy | |
| run: make -f Makefile clippy | |
| - name: Run doc tests | |
| run: make -f Makefile doc-test | |
| dependencies: | |
| runs-on: ubuntu-latest | |
| container: | |
| image: fedora:44 # CURRENT DEVELOPMENT ENVIRONMENT | |
| steps: | |
| - name: Install git for checkout action | |
| run: dnf install -y git | |
| - uses: actions/checkout@v6 | |
| with: | |
| path: loopdev-3 | |
| persist-credentials: false | |
| - uses: actions-rust-lang/setup-rust-toolchain@v1 | |
| with: | |
| components: cargo | |
| rust-src-dir: loopdev-3 | |
| - name: Install dependencies for Fedora | |
| run: > | |
| dnf install -y | |
| curl | |
| make | |
| openssl-devel | |
| python-requests | |
| python-semantic_version | |
| - name: Check out ci repo | |
| uses: actions/checkout@v6 | |
| with: | |
| path: ci | |
| repository: stratis-storage/ci | |
| persist-credentials: false | |
| - name: Run comparisons of version specs with Fedora packages | |
| run: | | |
| COMPARE_FEDORA_VERSIONS=$GITHUB_WORKSPACE/ci/dependency_management/compare_fedora_versions FEDORA_RELEASE=rawhide IGNORE_ARGS="--ignore-category low" make -f Makefile check-fedora-versions | |
| COMPARE_FEDORA_VERSIONS=$GITHUB_WORKSPACE/ci/dependency_management/compare_fedora_versions FEDORA_RELEASE=f44 IGNORE_ARGS="--ignore-category low" make -f Makefile check-fedora-versions | |
| COMPARE_FEDORA_VERSIONS=$GITHUB_WORKSPACE/ci/dependency_management/compare_fedora_versions FEDORA_RELEASE=f43 IGNORE_ARGS="--ignore-category low" make -f Makefile check-fedora-versions | |
| working-directory: loopdev-3 | |
| general_checks: | |
| uses: stratis-storage/github-actions/.github/workflows/reusable_general.yml@master | |
| with: | |
| fedora-container-image-number: 44 # CURRENT DEVELOPMENT ENVIRONMENT | |
| commit-checks: | |
| uses: stratis-storage/github-actions/.github/workflows/commits.yml@master | |
| with: | |
| fedora-container-image-number: 44 # CURRENT DEVELOPMENT ENVIRONMENT |