Merge pull request #307828 from philiptaron/issue-208242/texlive
texlive: avoid top-level `with` in helper script
This commit is contained in:
commit
6a72138d19
@ -1,10 +1,23 @@
|
|||||||
with import ../../../../.. { };
|
{ pkgs ? (import ../../../../.. { }) }:
|
||||||
|
|
||||||
with lib; let
|
let
|
||||||
getFods = drv: lib.optional (isDerivation drv.tex) (drv.tex // { tlType = "run"; })
|
inherit (pkgs) runCommand writeText texlive nix;
|
||||||
++ lib.optional (drv ? texdoc) (drv.texdoc // { tlType = "doc"; })
|
inherit (pkgs.lib)
|
||||||
++ lib.optional (drv ? texsource) (drv.texsource // { tlType = "source"; })
|
attrValues
|
||||||
++ lib.optional (drv ? tlpkg) (drv.tlpkg // { tlType = "tlpkg"; });
|
concatMap
|
||||||
|
concatMapStrings
|
||||||
|
isDerivation
|
||||||
|
filter
|
||||||
|
optional
|
||||||
|
optionalString
|
||||||
|
sort
|
||||||
|
strings
|
||||||
|
;
|
||||||
|
|
||||||
|
getFods = drv: optional (isDerivation drv.tex) (drv.tex // { tlType = "run"; })
|
||||||
|
++ optional (drv ? texdoc) (drv.texdoc // { tlType = "doc"; })
|
||||||
|
++ optional (drv ? texsource) (drv.texsource // { tlType = "source"; })
|
||||||
|
++ optional (drv ? tlpkg) (drv.tlpkg // { tlType = "tlpkg"; });
|
||||||
|
|
||||||
sorted = sort (a: b: a.pname < b.pname) (attrValues texlive.pkgs);
|
sorted = sort (a: b: a.pname < b.pname) (attrValues texlive.pkgs);
|
||||||
fods = concatMap getFods sorted;
|
fods = concatMap getFods sorted;
|
||||||
|
Loading…
Reference in New Issue
Block a user