Skip to content

Commit

Permalink
fix: required input lazy on lib
Browse files Browse the repository at this point in the history
  • Loading branch information
blaggacao committed Sep 15, 2023
1 parent a392e57 commit a78e6e8
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 13 deletions.
6 changes: 5 additions & 1 deletion flake.nix
Original file line number Diff line number Diff line change
Expand Up @@ -71,5 +71,9 @@
};
in
assert inputs.nixpkgs.lib.assertMsg ((builtins.compareVersions builtins.nixVersion "2.13") >= 0) "The truth is: you'll need a newer nix version to use Standard (minimum: v2.13).";
(import ./dogfood.nix (inputs // {inherit std;})) std;
(import ./dogfood.nix (inputs
// {
std = std // {inherit (inputs.self) narHash;};
}))
std;
}
13 changes: 5 additions & 8 deletions src/lib/dev/mkMakes.nix
Original file line number Diff line number Diff line change
@@ -1,11 +1,10 @@
let
inherit (inputs.cells.std.errors) requireInput;
inherit (requireInput "makes" "github:fluidattacks/makes" "std.lib.dev.mkMakes") nixpkgs makes;
inherit (nixpkgs) lib;

makes' = lib.fix (
lib.extends
(
inherit (inputs.nixpkgs.lib) customisation fix extends;
in
customisation.callPackageWith (fix (
extends (
_: _: {
inherit inputs;
inherit (nixpkgs) system;
Expand All @@ -17,6 +16,4 @@ let
import (makes + /src/args/agnostic.nix) {inherit (nixpkgs) system;}
)
.__unfix__
);
in
lib.customisation.callPackageWith makes'
))
7 changes: 3 additions & 4 deletions src/std/errors/requireInput.nix
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,7 @@
body = ''
In order to use ${target}, add to {bold}flake.nix{un-bold}:
inputs.std.inputs.${input}.url =
"${url}";
inputs.std.inputs.${input}.url = "${url}";
'';

inputs' = let
Expand Down Expand Up @@ -63,7 +62,7 @@ in
🏗️ │ {bold}Input Overloading for ${target}{un-bold}
─────┼─────────────────────────────────────────────────────────────────────────
📝 │ {italic}${indent body}{un-italic}
─────┼─────────────────────────────────────────────────────────────────────────
🙋 │ ${indent inputs'}
─────┴─────────────────────────────────────────────────────────────────────────
🙋 ${indent inputs'}
───────────────────────────────────────────────────────────────────────────────
''); inputs

0 comments on commit a78e6e8

Please sign in to comment.