From 3fa176577b655ede19f3a1425a775e5ec0985c3c Mon Sep 17 00:00:00 2001 From: Gavin John Date: Tue, 1 Jul 2025 15:55:37 -0400 Subject: [PATCH] Revert "use builtin fetchers to prevent importing from derivation" This reverts commit 124ffb8b10b43973bc8756ba1005f03f608effd0. --- default.nix | 5 ++--- lib/repoSource.nix | 12 ++---------- 2 files changed, 4 insertions(+), 13 deletions(-) diff --git a/default.nix b/default.nix index e2067e750..876cd6e63 100644 --- a/default.nix +++ b/default.nix @@ -5,7 +5,7 @@ pkgs ? ( import { overrides = [ - (final: prev: if prev ? nur then prev else { nur = import ./. { pkgs = final; }; }) + (final: prev: if prev ? nur then prev else { nur = ./. { pkgs = final; }; }) ]; } ), @@ -28,8 +28,7 @@ let lockedRevisions lib ; - fetchgit = builtins.fetchGit or nurpkgs.fetchgit; - fetchzip = builtins.fetchTarball or nurpkgs.fetchzip; + inherit (nurpkgs) fetchgit fetchzip; }; createRepo = diff --git a/lib/repoSource.nix b/lib/repoSource.nix index da3520554..f28a21411 100644 --- a/lib/repoSource.nix +++ b/lib/repoSource.nix @@ -47,14 +47,6 @@ else if (lib.hasPrefix "https://gitlab.com" attr.url || type == "gitlab") && !su else fetchgit { inherit (attr) url; - inherit (revision) rev; + inherit (revision) rev sha256; + fetchSubmodules = submodules; } - // ( - if fetchgit == builtins.fetchGit or null then - { inherit submodules; } - else - { - inherit (revision) sha256; - fetchSubmodules = submodules; - } - )