From 077f3e11704a72b1aa10e24eb83f703abaabbaa0 Mon Sep 17 00:00:00 2001 From: Lorenz Leutgeb Date: Fri, 12 Apr 2024 12:13:00 +0200 Subject: [PATCH] ci: Use Cachix if PR is not from a fork --- .github/workflows/pull_request.yaml | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/.github/workflows/pull_request.yaml b/.github/workflows/pull_request.yaml index 8041df5e..6c8e9de1 100644 --- a/.github/workflows/pull_request.yaml +++ b/.github/workflows/pull_request.yaml @@ -12,7 +12,13 @@ jobs: with: extra-conf: | experimental-features = no-url-literals + - uses: cachix/cachix-action@v10 + if: ${{ !github.event.pull_request.head.repo.fork }} + with: + name: ngi + authToken: '${{ secrets.CACHIX_AUTH_TOKEN }}' - uses: DeterminateSystems/magic-nix-cache-action@main + if: ${{ github.event.pull_request.head.repo.fork }} with: upstream-cache: https://ngi.cachix.org/ - id: flake-show-diff