Use harmonia-store-core to save on a lot of code
#47
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: CI | |
| on: | |
| push: | |
| branches: [ main ] | |
| pull_request: | |
| types: [ opened, reopened, labeled, synchronize ] | |
| jobs: | |
| build: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Setup Nix | |
| uses: ./.github/actions/setup-nix | |
| - name: Cache Rust Artifacts | |
| uses: actions/cache@v4 | |
| env: | |
| cache-name: cache-rust-artifacts | |
| with: | |
| path: | | |
| /home/runner/.cargo | |
| target | |
| key: ${{ runner.os }}-${{ env.cache-name }}-${{ hashFiles('**/Cargo.toml', '**/Cargo.lock', '**/.cargo/config.toml', '**/rust-toolchain.toml', '**/flake.nix', '**/flake.lock') }} | |
| - name: Build | |
| run: | | |
| eval "$(nix print-dev-env)" | |
| set -x | |
| cargo fmt --check | |
| cargo clippy | |
| cargo test | |
| lint: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Setup Nix | |
| uses: ./.github/actions/setup-nix | |
| - name: Run nix flake check | |
| run: nix flake check -L | |
| integration-test: | |
| runs-on: ubuntu-latest | |
| strategy: | |
| matrix: | |
| test: | |
| - nix-build-hello | |
| - nix-build-header | |
| - nix-build-multi-source | |
| - nix-build-shared-lib | |
| - nix-build-dynamic-deps | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Setup Nix | |
| uses: ./.github/actions/setup-nix | |
| - name: Build NixOS test driver | |
| run: nix build -L .#driver-${{ matrix.test }} | |
| - name: Run integration tests | |
| run: nix run -L .#test-${{ matrix.test }} |