From 012ef2b62f7f67193c1a2615c3e25c38965a9ea6 Mon Sep 17 00:00:00 2001 From: Malte Brandy Date: Fri, 26 Jun 2020 19:14:45 +0200 Subject: [PATCH] Try buildlogFile --- overlays/testing.nix | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/overlays/testing.nix b/overlays/testing.nix index 87593694..ef179276 100644 --- a/overlays/testing.nix +++ b/overlays/testing.nix @@ -7,11 +7,15 @@ let homes = self.lib.attrNames (import ../home/modes.nix); keys = [ "default" "apollo" "hera" ]; haskellBody = name: commandline: '' + command = ${commandline} main = do (configDir:hostname:args) <- getArgs paths <- myNixPath $ toText configDir say [i|Trying to build ${name} config for #{hostname} ...|] - ${commandline} + bracket + (decodeUtf8 <$> mktemp |> captureTrim) + rm + \logFile -> onException (command &> Append logFile &!> Append logFile) (cat logFile) say [i|Build of ${name} config for #{hostname} was successful.|] ''; in {