Mercurial > public > mercurial-scm > hg-stable
diff mercurial/httprepo.py @ 11153:9936ed1d04f4
push: document return values between various repo methods.
This starts at localrepository.push() and seeps down to
push_addchangegroup(), push_unbundle(), prepush(), addchangegroup(),
and leaks out to sshrepository.unbundle(), sshrepository.addchangegroup(),
and httprepository.unbundle(). Seems to cover everything you ever
wanted to know about pushing but were afraid to ask.
author | Greg Ward <greg-hg@gerg.ca> |
---|---|
date | Sun, 02 May 2010 21:56:25 -0400 |
parents | 2e1a9b811d13 |
children | db3f6f0e4e7d |
line wrap: on
line diff
--- a/mercurial/httprepo.py Sat May 01 18:39:40 2010 -0400 +++ b/mercurial/httprepo.py Sun May 02 21:56:25 2010 -0400 @@ -208,6 +208,12 @@ return util.chunkbuffer(zgenerator(f)) def unbundle(self, cg, heads, source): + '''Send cg (a readable file-like object representing the + changegroup to push, typically a chunkbuffer object) to the + remote server as a bundle. Return an integer response code: + non-zero indicates a successful push (see + localrepository.addchangegroup()), and zero indicates either + error or nothing to push.''' # have to stream bundle to a temp file because we do not have # http 1.1 chunked transfer.