Skip to content

Commit

Permalink
ci: matrix build + base version
Browse files Browse the repository at this point in the history
  • Loading branch information
igordejanovic committed Jun 12, 2024
1 parent cc89f8a commit 97f2ca3
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 2 deletions.
9 changes: 8 additions & 1 deletion .github/workflows/checks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,11 +17,18 @@ permissions:
jobs:
check:
runs-on: ubuntu-latest
strategy:
matrix:
rust:
- base
- stable
- beta
- nightly
steps:
- uses: actions/checkout@v4
- uses: cachix/install-nix-action@v27
with:
nix_path: nixpkgs=channel:nixos-unstable
- uses: DeterminateSystems/magic-nix-cache-action@v6
- name: Run checks
run: nix flake check
run: nix build .#checks.x86_64-linux.${{ matrix.rust }}
3 changes: 2 additions & 1 deletion default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ let
name = "rustemo-workspace-check";

# A convenience for running each individual check when needed from CLI.
# E.g.: nix build .\#checks.x86_64-linux.stable.clippy
# E.g.: nix build .#checks.x86_64-linux.stable.clippy
# Until this is solved: https://github.com/NixOS/nix/issues/8881
inherit tests clippy fmt;

Expand All @@ -78,6 +78,7 @@ in
{
buildInputs = [ pkgs.rust-bin.stable.latest.default ];
checks = with pkgs.rust-bin; {
base = workspaceChecksForToolchain stable."1.74.1".default;
stable = workspaceChecksForToolchain stable.latest.default;
beta = workspaceChecksForToolchain beta.latest.default;
nightly = workspaceChecksForToolchain nightly.latest.default;
Expand Down

0 comments on commit 97f2ca3

Please sign in to comment.