fix handling of nonexistant hook

This commit is contained in:
Joey Hess 2014-03-03 13:59:36 -04:00
parent cf8788fb49
commit 04b77328ef
Failed to extract signature

View file

@ -65,6 +65,7 @@ runAnnexHook hook = do
when exists $
run cmd
where
hookexists f = liftIO $ isExecutable . fileMode <$> getFileStatus f
hookexists f = liftIO $ catchBoolIO $
isExecutable . fileMode <$> getFileStatus f
run cmd = unlessM (liftIO $ boolSystem cmd []) $
warning $ cmd ++ " failed"