diff options
author | Joey Hess <joey@kitenet.net> | 2013-11-19 16:09:44 -0400 |
---|---|---|
committer | Joey Hess <joey@kitenet.net> | 2013-11-19 16:09:44 -0400 |
commit | e011fd72ef69dbbaa4f63bfd61564e0918cb3e22 (patch) | |
tree | a371af17996f35ffa2d4bfa66c09a06124c40539 /Git/Repair.hs | |
parent | d39035d46df979abcf34d1411f96b5a70bd2d93c (diff) | |
download | git-repair-e011fd72ef69dbbaa4f63bfd61564e0918cb3e22.tar.gz |
initial work on git repository destroyer
I suspect this might sometimes corrupt the **source** repo, so use with
caution!
Diffstat (limited to 'Git/Repair.hs')
-rw-r--r-- | Git/Repair.hs | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/Git/Repair.hs b/Git/Repair.hs index 270b041..41d0535 100644 --- a/Git/Repair.hs +++ b/Git/Repair.hs @@ -8,6 +8,7 @@ module Git.Repair ( runRepair, runRepairOf, + successfulRepair, cleanCorruptObjects, retrieveMissingObjects, resetLocalBranches, @@ -452,6 +453,9 @@ runRepair forced g = do putStrLn "No problems found." return (True, S.empty, []) +successfulRepair :: (Bool, MissingObjects, [Branch]) -> Bool +successfulRepair = fst3 + runRepairOf :: FsckResults -> Bool -> Maybe FilePath -> Repo -> IO (Bool, MissingObjects, [Branch]) runRepairOf fsckresult forced referencerepo g = do missing <- cleanCorruptObjects fsckresult g |