diff options
author | Joey Hess <joey@kitenet.net> | 2014-03-03 13:59:36 -0400 |
---|---|---|
committer | Joey Hess <joey@kitenet.net> | 2014-03-03 13:59:36 -0400 |
commit | 8d6edac6f48a4bf1522b68a30db579193c097e7a (patch) | |
tree | 61c6701225d2a687a3a2cae346d80ddbabaeec46 /Annex/Hook.hs | |
parent | a01d7ee470230d8ff1fcfc598918f01d9a3687e5 (diff) |
fix handling of nonexistant hook
Diffstat (limited to 'Annex/Hook.hs')
-rw-r--r-- | Annex/Hook.hs | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/Annex/Hook.hs b/Annex/Hook.hs index a6fcf7131..4848e2d61 100644 --- a/Annex/Hook.hs +++ b/Annex/Hook.hs @@ -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" |