aboutsummaryrefslogtreecommitdiffstats
path: root/contrib/remote-helpers
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2013-04-26 15:18:26 -0700
committerJunio C Hamano <gitster@pobox.com>2013-04-26 15:18:26 -0700
commitdf8597258e630e6cf5553efd9748b9da4670f5e1 (patch)
treebf8c267198194301b0deef5fbe468dab7e173fac /contrib/remote-helpers
parentaedb94b3f05bf4fb6c95dbfdccf11ebd101e947a (diff)
parentfbd3f0e53ca9b88709ceadea48d9383c7ffa9382 (diff)
downloadgit-df8597258e630e6cf5553efd9748b9da4670f5e1.tar.gz
Merge branch 'fc/remote-bzr'
* fc/remote-bzr: remote-bzr: use proper push method
Diffstat (limited to 'contrib/remote-helpers')
-rwxr-xr-xcontrib/remote-helpers/git-remote-bzr10
1 files changed, 5 insertions, 5 deletions
diff --git a/contrib/remote-helpers/git-remote-bzr b/contrib/remote-helpers/git-remote-bzr
index aa7bc97bee..a622122c86 100755
--- a/contrib/remote-helpers/git-remote-bzr
+++ b/contrib/remote-helpers/git-remote-bzr
@@ -633,12 +633,12 @@ def do_export(parser):
for ref, revid in parsed_refs.iteritems():
if ref == 'refs/heads/master':
repo.generate_revision_history(revid, marks.get_tip('master'))
- revno, revid = repo.last_revision_info()
if peer:
- if hasattr(peer, "import_last_revision_info_and_tags"):
- peer.import_last_revision_info_and_tags(repo, revno, revid)
- else:
- peer.import_last_revision_info(repo.repository, revno, revid)
+ try:
+ repo.push(peer, stop_revision=revid)
+ except bzrlib.errors.DivergedBranches:
+ print "error %s non-fast forward" % ref
+ continue
else:
wt = repo.bzrdir.open_workingtree()
wt.update()