From 6401eecb57e04f35a93866c308f9396c5b19c2e8 Mon Sep 17 00:00:00 2001 From: Marien Zwart Date: Sat, 25 May 2024 12:46:43 +1000 Subject: [PATCH] Always fetch allRefs Having CI confirm allRefs false is still safe would require a network hit for each repo, which is already problematic. But https://github.com/NixOS/nix/issues/7120 means we'd need to drop CI's cached content, not just its cached refs: given how much we're fetching that seems too much. Fetch all refs unconditionally, assuming we're typically re-fetching the same fixed rev repeatedly, which should be cached. --- default.nix | 4 ++-- fetch-overrides.nix | 6 ------ 2 files changed, 2 insertions(+), 8 deletions(-) diff --git a/default.nix b/default.nix index 77777a0..634a387 100644 --- a/default.nix +++ b/default.nix @@ -52,7 +52,7 @@ }: let inherit (lib) optionalAttrs optionalString; - inherit (import ./fetch-overrides.nix) extraPins extraUrls allRefsRepos; + inherit (import ./fetch-overrides.nix) extraPins extraUrls; # Step 1: determine which Emacs packages to pull in. # @@ -239,7 +239,7 @@ let { inherit url; rev = pin; - allRefs = allRefsRepos.${url} or false; + allRefs = true; submodules = !(p.recipe.nonrecursive or false); # TODO: pull ref from derivation.src when not pulling it from p.recipe? # Note Doom does have packages with pin + branch (or nonrecursive) set, diff --git a/fetch-overrides.nix b/fetch-overrides.nix index 6fd7e3d..7baa28b 100644 --- a/fetch-overrides.nix +++ b/fetch-overrides.nix @@ -39,10 +39,4 @@ # In emacsattic, so shouldn't change underneath us. ammonite-term-repl = "b552fe21977e005c1c460bf6607557e67241a6b6"; }; - - # TODO figure out whether we're better off always setting allRefs. - allRefsRepos = { - "https://git.savannah.gnu.org/git/emms.git" = true; - "https://git.notmuchmail.org/git/notmuch" = true; - }; }