From c0730c50e7fe5bccc671aa4984507f6835b1d8ee Mon Sep 17 00:00:00 2001 From: Malte Brandy Date: Wed, 13 Jan 2021 20:11:46 +0100 Subject: [PATCH] Try another nix-jobs fix --- nixos/roles/laminar/nix-jobs.hs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/nixos/roles/laminar/nix-jobs.hs b/nixos/roles/laminar/nix-jobs.hs index cc19029a..6e2c962e 100644 --- a/nixos/roles/laminar/nix-jobs.hs +++ b/nixos/roles/laminar/nix-jobs.hs @@ -17,7 +17,6 @@ import Control.Concurrent.Async ( forConcurrently_ ) import Control.Concurrent.STM ( check , retry - , swapTVar ) import Control.Exception ( bracket , catch @@ -104,6 +103,7 @@ instance ExecArg Text where asArg = asArg . toString asArgFromList = asArgFromList . fmap toString +drvBasename :: Text -> Text drvBasename derivationName = fromMaybe derivationName . viaNonEmpty last $ splitOn "/" derivationName @@ -371,7 +371,7 @@ main = do sayErr [i|Missing executables #{show x}|] exitFailure args <- fmap toText <$> getArgs - case args of + handle (\(JobException e) -> sayErr e >> exitFailure) $ case args of ["realise-here", derivationName] -> job derivationName ["realise" , derivationName] -> do jobId <- getEnv "JOB"