aboutsummaryrefslogtreecommitdiff
path: root/Git/Branch.hs
diff options
context:
space:
mode:
authorGravatar Joey Hess <joey@kitenet.net>2013-05-21 18:24:29 -0400
committerGravatar Joey Hess <joey@kitenet.net>2013-05-21 18:24:29 -0400
commitb6ebb173e7b5d4d07577cb2918e7d1a24fbc1f60 (patch)
tree8c994e00b091c448d80737aa99bbc181701eee04 /Git/Branch.hs
parent14f2a42ca4131a7a51a9e10a94521639b971bccd (diff)
XMPP: Avoid redundant and unncessary pushes. Note that this breaks compatibility with previous versions of git-annex, which will refuse to accept any XMPP pushes from this version.
Diffstat (limited to 'Git/Branch.hs')
-rw-r--r--Git/Branch.hs3
1 files changed, 2 insertions, 1 deletions
diff --git a/Git/Branch.hs b/Git/Branch.hs
index 41ae2559e..d4a684016 100644
--- a/Git/Branch.hs
+++ b/Git/Branch.hs
@@ -13,6 +13,7 @@ import Common
import Git
import Git.Sha
import Git.Command
+import Git.Ref (headRef)
{- The currently checked out branch.
-
@@ -35,7 +36,7 @@ current r = do
{- The current branch, which may not really exist yet. -}
currentUnsafe :: Repo -> IO (Maybe Git.Ref)
currentUnsafe r = parse . firstLine
- <$> pipeReadStrict [Param "symbolic-ref", Param "HEAD"] r
+ <$> pipeReadStrict [Param "symbolic-ref", Param $ show headRef] r
where
parse l
| null l = Nothing