summaryrefslogtreecommitdiff
path: root/Command/Sync.hs
diff options
context:
space:
mode:
authorGravatar Joey Hess <joey@kitenet.net>2014-02-19 01:09:17 -0400
committerGravatar Joey Hess <joey@kitenet.net>2014-02-19 01:19:57 -0400
commit51c12a76ef54affaf9428232fde4f2c3e30e7488 (patch)
tree4cb2699e2b410260e383d3bf6da14d502aa0d0dc /Command/Sync.hs
parentb5b5ead4b28fd08100bcac9cb9482263bac3a64e (diff)
remove Read instance for Ref
Removed instance, got it all to build using fromRef. (With a few things that really need to show something using a ref for debugging stubbed out.) Then added back Read instance, and made Logs.View use it for serialization. This changes the view log format.
Diffstat (limited to 'Command/Sync.hs')
-rw-r--r--Command/Sync.hs10
1 files changed, 5 insertions, 5 deletions
diff --git a/Command/Sync.hs b/Command/Sync.hs
index 90b9a6c79..f041b5d23 100644
--- a/Command/Sync.hs
+++ b/Command/Sync.hs
@@ -192,12 +192,12 @@ pushLocal (Just branch) = do
updateBranch :: Git.Ref -> Git.Repo -> IO ()
updateBranch syncbranch g =
- unlessM go $ error $ "failed to update " ++ show syncbranch
+ unlessM go $ error $ "failed to update " ++ Git.fromRef syncbranch
where
go = Git.Command.runBool
[ Param "branch"
, Param "-f"
- , Param $ show $ Git.Ref.base syncbranch
+ , Param $ Git.fromRef $ Git.Ref.base syncbranch
] g
pullRemote :: Remote -> Maybe Git.Ref -> CommandStart
@@ -283,15 +283,15 @@ pushBranch remote branch g = tryIO (directpush g) `after` syncpush g
, refspec branch
]
directpush = Git.Command.runQuiet $ pushparams
- [show $ Git.Ref.base $ fromDirectBranch branch]
+ [Git.fromRef $ Git.Ref.base $ fromDirectBranch branch]
pushparams branches =
[ Param "push"
, Param $ Remote.name remote
] ++ map Param branches
refspec b = concat
- [ show $ Git.Ref.base b
+ [ Git.fromRef $ Git.Ref.base b
, ":"
- , show $ Git.Ref.base $ syncBranch b
+ , Git.fromRef $ Git.Ref.base $ syncBranch b
]
commitAnnex :: CommandStart