Skip conversion of app attributes if they are already apps

This commit is contained in:
Archit Gupta 2023-04-13 22:57:23 -07:00
parent dab3eb948d
commit e91836b9d3

View File

@ -134,12 +134,16 @@ let
touch $out
'';
mkApp = lib: program: {
isApp = x: (x ? type) && (x.type == "app") && (x ? program);
mkApp = lib: app:
if isApp app then app
else {
type = "app";
program =
if lib.isDerivation program
then lib.getExe program
else program;
if lib.isDerivation app
then lib.getExe app
else app;
};
eachSystem = fn: foldAttrs mergeAttrs { } (map