function to lib, packages for any system
This commit is contained in:
parent
5963940d6b
commit
4b8974f7aa
15
flake.nix
15
flake.nix
|
@ -7,12 +7,17 @@
|
||||||
sfnt2woff-zopfli = callPackage ./sfnt2woff-zopfli.nix {};
|
sfnt2woff-zopfli = callPackage ./sfnt2woff-zopfli.nix {};
|
||||||
fetchfont = callPackage ./fetchfont.nix {sfnt2woff-zopfli = sfnt2woff-zopfli; };
|
fetchfont = callPackage ./fetchfont.nix {sfnt2woff-zopfli = sfnt2woff-zopfli; };
|
||||||
fonts = callPackage ./fonts.nix {fetchfont = fetchfont; };
|
fonts = callPackage ./fonts.nix {fetchfont = fetchfont; };
|
||||||
in
|
allSystems = [ "x86_64-linux" "aarch64-linux" "x86_64-darwin" "aarch64-darwin" ];
|
||||||
|
forAllSystems = f: nixpkgs.lib.genAttrs allSystems (system: f {
|
||||||
|
pkgs = import nixpkgs { inherit system; };
|
||||||
|
});
|
||||||
|
in {
|
||||||
|
lib = {
|
||||||
fetchfont = fetchfont;
|
fetchfont = fetchfont;
|
||||||
|
};
|
||||||
defaultPackage.x86_64-linux =
|
packages = forAllSystems {pkgs}: {
|
||||||
with import nixpkgs { system = "x86_64-linux"; };
|
default = fonts // { sfnt2woff-zopfli = sfnt2woff-zopfli; };
|
||||||
fonts // { sfnt2woff-zopfli = sfnt2woff-zopfli; };
|
};
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue