From 1340de563bfbbe11a34a9f2a2820a4dc77f46ccd Mon Sep 17 00:00:00 2001 From: prescientmoon Date: Sat, 24 Feb 2024 04:27:19 +0100 Subject: [PATCH] Return to old homer asset handling --- pkgs/homer.nix | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) diff --git a/pkgs/homer.nix b/pkgs/homer.nix index d50956b..cd825b6 100644 --- a/pkgs/homer.nix +++ b/pkgs/homer.nix @@ -23,13 +23,15 @@ let text = builtins.toJSON config; destination = "/assets/config.yml"; }) - ] ++ extraAssets; - - postBuid = lib.concatStringsSep "\n" (map - (asset: '' - mv $out/${asset} $out/assets/${asset} - '') - extraAssets); + ] ++ + lib.optional (extraAssets != [ ]) + (runCommandLocal "homer-assets${nameSuffix}" { } + (builtins.concatStringsSep "\n" (map + (asset: '' + mkdir -p $out/assets/${dirOf asset} + ln -s ${asset} $out/assets/${asset} + '') + extraAssets))); }; }; };