aboutsummaryrefslogtreecommitdiff
path: root/Command
diff options
context:
space:
mode:
Diffstat (limited to 'Command')
-rw-r--r--Command/Watch.hs7
1 files changed, 5 insertions, 2 deletions
diff --git a/Command/Watch.hs b/Command/Watch.hs
index 7b714ac18..d6f77b6ae 100644
--- a/Command/Watch.hs
+++ b/Command/Watch.hs
@@ -43,14 +43,17 @@ start = notBareRepo $ do
mvar <- liftIO $ newMVar state
next $ next $ liftIO $ withINotify $ \i -> do
let hook a = Just $ runAnnex mvar a
- watchDir i "." (not . pruned)
+ watchDir i "." (ignored . takeFileName)
(hook onAdd) (hook onAddSymlink)
(hook onDel) (hook onDelDir)
putStrLn "(started)"
waitForTermination
return True
where
- pruned dir = takeFileName dir /= ".git"
+ ignored ".git" = True
+ ignored ".gitignore" = True
+ ignored ".gitattributes" = True
+ ignored _ = False
{- Runs a handler, inside the Annex monad.
-