summaryrefslogtreecommitdiff
path: root/Assistant
diff options
context:
space:
mode:
authorGravatar Joey Hess <joey@kitenet.net>2014-01-22 17:11:41 -0400
committerGravatar Joey Hess <joey@kitenet.net>2014-01-22 17:11:41 -0400
commit9042ae3f4a12e2af802557f571bb793ab94b40d3 (patch)
tree7dd0b7b938a08f8bad44b13ec91c53e07c66c426 /Assistant
parenteb411b9c27437a57fede7d787d82a80920c2962e (diff)
assistant: Run the periodic git gc in batch mode.
Diffstat (limited to 'Assistant')
-rw-r--r--Assistant/Threads/SanityChecker.hs3
1 files changed, 2 insertions, 1 deletions
diff --git a/Assistant/Threads/SanityChecker.hs b/Assistant/Threads/SanityChecker.hs
index 8aa691cdc..a1be8dffc 100644
--- a/Assistant/Threads/SanityChecker.hs
+++ b/Assistant/Threads/SanityChecker.hs
@@ -122,6 +122,7 @@ waitForNextCheck = do
dailyCheck :: Assistant Bool
dailyCheck = do
g <- liftAnnex gitRepo
+ batchmaker <- liftIO getBatchCommandMaker
-- Find old unstaged symlinks, and add them to git.
(unstaged, cleanup) <- liftIO $ Git.LsFiles.notInRepo False ["."] g
@@ -140,7 +141,7 @@ dailyCheck = do
- to have a lot of small objects and they should not be a
- significant size. -}
when (Git.Config.getMaybe "gc.auto" g == Just "0") $
- liftIO $ void $ Git.Command.runBool
+ liftIO $ void $ Git.Command.runBatch batchmaker
[ Param "-c", Param "gc.auto=670000"
, Param "gc"
, Param "--auto"