summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGravatar Joey Hess <joey@kitenet.net>2011-07-04 15:55:03 -0400
committerGravatar Joey Hess <joey@kitenet.net>2011-07-04 15:55:03 -0400
commit5beb6bc76fb3edbc28c238eb9596fc828aa49bfc (patch)
tree5068c9b0de21ffb1906743c0c7bda0b5cbbd9d6a
parent9d7b35f7addee7194a40784e06dfbdc9a8d2fa34 (diff)
uninit: delete .git/annex/
-rw-r--r--Command/Uninit.hs9
-rw-r--r--debian/changelog2
2 files changed, 7 insertions, 4 deletions
diff --git a/Command/Uninit.hs b/Command/Uninit.hs
index 22006f7dc..5cb66e83a 100644
--- a/Command/Uninit.hs
+++ b/Command/Uninit.hs
@@ -21,6 +21,7 @@ import qualified Command.Unannex
import qualified Command.Init
import qualified Branch
import Content
+import Locations
command :: [Command]
command = [repoCommand "uninit" paramPath seek
@@ -40,9 +41,11 @@ cleanup = do
g <- Annex.gitRepo
gitPreCommitHookUnWrite g
saveState
- liftIO $ Git.run g "branch" [Param "-D", Param Branch.name]
- -- bypass normal shutdown, which writes to the deleted branch
- liftIO exitSuccess
+ liftIO $ do
+ Git.run g "branch" [Param "-D", Param Branch.name]
+ removeDirectoryRecursive (gitAnnexDir g)
+ -- avoid normal shutdown
+ exitSuccess
gitPreCommitHookUnWrite :: Git.Repo -> Annex ()
gitPreCommitHookUnWrite repo = do
diff --git a/debian/changelog b/debian/changelog
index fb5b80ac0..3564acd17 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,6 +1,6 @@
git-annex (3.20110703) UNRELEASED; urgency=low
- * uninit: Delete the git-annex branch.
+ * uninit: Delete the git-annex branch and .git/annex/
-- Joey Hess <joeyh@debian.org> Mon, 04 Jul 2011 15:50:21 -0400