From c38150fc45f043c1f66fe399ab422be5c6618ba0 Mon Sep 17 00:00:00 2001 From: louib Date: Sat, 7 Mar 2026 10:10:29 -0500 Subject: [PATCH] fix: pin nix version --- .github/workflows/ci.yml | 35 ++++++++++++++++++++++++++++++----- .github/workflows/merge.yml | 21 ++++++++++++++++++--- .nix-version | 1 + flake.lock | 6 +++--- 4 files changed, 52 insertions(+), 11 deletions(-) create mode 100644 .nix-version diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index b017841..7d15ec7 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -27,7 +27,12 @@ jobs: - uses: actions/checkout@v6 with: fetch-depth: 1 - - uses: DeterminateSystems/nix-installer-action@v21 + - name: Get Nix version + id: nix-version + run: echo "version=$(cat .nix-version)" >> $GITHUB_OUTPUT + - uses: cachix/install-nix-action@19effe9fe722874e6d46dd7182e4b8b7a43c4a99 # v31 + with: + install_url: https://releases.nixos.org/nix/nix-${{ steps.nix-version.outputs.version }}/install - name: run cargo doc run: nix develop --command cargo doc @@ -36,7 +41,12 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@v6 - - uses: DeterminateSystems/nix-installer-action@v21 + - name: Get Nix version + id: nix-version + run: echo "version=$(cat .nix-version)" >> $GITHUB_OUTPUT + - uses: cachix/install-nix-action@19effe9fe722874e6d46dd7182e4b8b7a43c4a99 # v31 + with: + install_url: https://releases.nixos.org/nix/nix-${{ steps.nix-version.outputs.version }}/install - name: Code Formatting run: | nix develop --command cargo fmt --check @@ -68,7 +78,12 @@ jobs: RUSTFLAGS: -D warnings steps: - uses: actions/checkout@v6 - - uses: DeterminateSystems/nix-installer-action@v21 + - name: Get Nix version + id: nix-version + run: echo "version=$(cat .nix-version)" >> $GITHUB_OUTPUT + - uses: cachix/install-nix-action@19effe9fe722874e6d46dd7182e4b8b7a43c4a99 # v31 + with: + install_url: https://releases.nixos.org/nix/nix-${{ steps.nix-version.outputs.version }}/install - name: Build the project with all the features run: nix develop --command cargo build --all-features @@ -86,7 +101,12 @@ jobs: RUSTFLAGS: -D warnings steps: - uses: actions/checkout@v6 - - uses: DeterminateSystems/nix-installer-action@v21 + - name: Get Nix version + id: nix-version + run: echo "version=$(cat .nix-version)" >> $GITHUB_OUTPUT + - uses: cachix/install-nix-action@19effe9fe722874e6d46dd7182e4b8b7a43c4a99 # v31 + with: + install_url: https://releases.nixos.org/nix/nix-${{ steps.nix-version.outputs.version }}/install - name: run cargo test run: nix develop --command cargo test --all-features @@ -95,7 +115,12 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@v6 - - uses: DeterminateSystems/nix-installer-action@v21 + - name: Get Nix version + id: nix-version + run: echo "version=$(cat .nix-version)" >> $GITHUB_OUTPUT + - uses: cachix/install-nix-action@19effe9fe722874e6d46dd7182e4b8b7a43c4a99 # v31 + with: + install_url: https://releases.nixos.org/nix/nix-${{ steps.nix-version.outputs.version }}/install - name: Verify code coverage run: | nix develop --command cargo tarpaulin --verbose --timeout 120 diff --git a/.github/workflows/merge.yml b/.github/workflows/merge.yml index 88ac81e..8c55ba2 100644 --- a/.github/workflows/merge.yml +++ b/.github/workflows/merge.yml @@ -12,7 +12,12 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@v6 - - uses: DeterminateSystems/nix-installer-action@v21 + - name: Get Nix version + id: nix-version + run: echo "version=$(cat .nix-version)" >> $GITHUB_OUTPUT + - uses: cachix/install-nix-action@19effe9fe722874e6d46dd7182e4b8b7a43c4a99 # v31 + with: + install_url: https://releases.nixos.org/nix/nix-${{ steps.nix-version.outputs.version }}/install - name: Verify code coverage run: | nix develop --command cargo tarpaulin --verbose --timeout 120 @@ -29,7 +34,12 @@ jobs: RUSTFLAGS: -D warnings steps: - uses: actions/checkout@v6 - - uses: DeterminateSystems/nix-installer-action@v21 + - name: Get Nix version + id: nix-version + run: echo "version=$(cat .nix-version)" >> $GITHUB_OUTPUT + - uses: cachix/install-nix-action@19effe9fe722874e6d46dd7182e4b8b7a43c4a99 # v31 + with: + install_url: https://releases.nixos.org/nix/nix-${{ steps.nix-version.outputs.version }}/install - name: run cargo build run: nix develop --command cargo build --all-features @@ -83,7 +93,12 @@ jobs: sed -i 's/0.0.0-placeholder-version/${{ env.next-version }}/' Cargo.toml git diff - - uses: DeterminateSystems/nix-installer-action@c5a866b6ab867e88becbed4467b93592bce69f8a # v21 + - name: Get Nix version + id: nix-version + run: echo "version=$(cat .nix-version)" >> $GITHUB_OUTPUT + - uses: cachix/install-nix-action@19effe9fe722874e6d46dd7182e4b8b7a43c4a99 # v31 + with: + install_url: https://releases.nixos.org/nix/nix-${{ steps.nix-version.outputs.version }}/install - uses: rust-lang/crates-io-auth-action@b7e9a28eded4986ec6b1fa40eeee8f8f165559ec # v1.0.3 id: auth diff --git a/.nix-version b/.nix-version new file mode 100644 index 0000000..2cd5858 --- /dev/null +++ b/.nix-version @@ -0,0 +1 @@ +2.18.9 diff --git a/flake.lock b/flake.lock index 8739430..e4e7135 100644 --- a/flake.lock +++ b/flake.lock @@ -20,11 +20,11 @@ }, "nixpkgs": { "locked": { - "lastModified": 1770310347, - "narHash": "sha256-TMj1xLiq0QDtPsLaObldyhTVaLQBcxFSDW+o18dA1xE=", + "lastModified": 1772895724, + "narHash": "sha256-pHS6KqPwRrZRib8noJq6evO1eT+MClsXBloKdmS05Ug=", "owner": "nixos", "repo": "nixpkgs", - "rev": "d5a9a8d404e990df2a91205e3b36989fc04d14bb", + "rev": "05a293da4d2983134d3ad4651d8ddb261f56891f", "type": "github" }, "original": {