use builtin fetchers to prevent importing from derivation
This commit is contained in:
parent
8f1f3d25ea
commit
124ffb8b10
2 changed files with 13 additions and 4 deletions
|
|
@ -5,7 +5,7 @@
|
|||
pkgs ? (
|
||||
import <nixpkgs> {
|
||||
overrides = [
|
||||
(final: prev: if prev ? nur then prev else { nur = ./. { pkgs = final; }; })
|
||||
(final: prev: if prev ? nur then prev else { nur = import ./. { pkgs = final; }; })
|
||||
];
|
||||
}
|
||||
),
|
||||
|
|
@ -28,7 +28,8 @@ let
|
|||
lockedRevisions
|
||||
lib
|
||||
;
|
||||
inherit (nurpkgs) fetchgit fetchzip;
|
||||
fetchgit = builtins.fetchGit or nurpkgs.fetchgit;
|
||||
fetchzip = builtins.fetchTarball or nurpkgs.fetchzip;
|
||||
};
|
||||
|
||||
createRepo =
|
||||
|
|
|
|||
|
|
@ -47,6 +47,14 @@ else if (lib.hasPrefix "https://gitlab.com" attr.url || type == "gitlab") && !su
|
|||
else
|
||||
fetchgit {
|
||||
inherit (attr) url;
|
||||
inherit (revision) rev sha256;
|
||||
fetchSubmodules = submodules;
|
||||
inherit (revision) rev;
|
||||
}
|
||||
// (
|
||||
if fetchgit == builtins.fetchGit or null then
|
||||
{ inherit submodules; }
|
||||
else
|
||||
{
|
||||
inherit (revision) sha256;
|
||||
fetchSubmodules = submodules;
|
||||
}
|
||||
)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue