summaryrefslogtreecommitdiff
path: root/Core.hs
diff options
context:
space:
mode:
authorGravatar Joey Hess <joey@kitenet.net>2010-10-26 15:59:50 -0400
committerGravatar Joey Hess <joey@kitenet.net>2010-10-26 15:59:50 -0400
commitef26076a5a3df9b8740883e3f7b3b68585b47ad5 (patch)
tree4866077b46f25ba1446ddebf7d5b151fc98fd8ac /Core.hs
parent4cda7b6e7c2f08c99b0c4c14bb86e691903a985b (diff)
add git queue to Annex monad
not used anywhere just yet..
Diffstat (limited to 'Core.hs')
-rw-r--r--Core.hs9
1 files changed, 9 insertions, 0 deletions
diff --git a/Core.hs b/Core.hs
index 881b668e0..4c7c9205e 100644
--- a/Core.hs
+++ b/Core.hs
@@ -14,6 +14,7 @@ import Locations
import LocationLog
import UUID
import qualified GitRepo as Git
+import qualified GitQueue
import qualified Annex
import Utility
@@ -30,6 +31,14 @@ shutdown :: Annex Bool
shutdown = do
g <- Annex.gitRepo
+ -- Runs all queued git commands.
+ q <- Annex.queueGet
+ if (q == GitQueue.empty)
+ then return ()
+ else do
+ liftIO $ putStrLn "Recording state in git..."
+ liftIO $ GitQueue.run g q
+
liftIO $ Git.run g ["add", gitStateDir g]
-- clean up any files left in the temp directory, but leave