Mercurial > evolve
changeset 89:757153438e58
[obsolet] base64 encore obsolete rel for pushkey
Yop this is ugly
author | Pierre-Yves David <pierre-yves.david@logilab.fr> |
---|---|
date | Mon, 19 Sep 2011 18:27:30 +0200 |
parents | 64fe5a4f877e |
children | a5f6194eb05c |
files | hgext/obsolete.py |
diffstat | 1 files changed, 5 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/hgext/obsolete.py Mon Sep 19 18:03:51 2011 +0200 +++ b/hgext/obsolete.py Mon Sep 19 18:27:30 2011 +0200 @@ -80,6 +80,8 @@ from mercurial.i18n import _ +import base64 + from mercurial import util from mercurial import context from mercurial import revset @@ -221,7 +223,7 @@ XXX this have be improved""" tmp = StringIO() _obsserialise(repo._obssubrels, tmp) - return {'relations': tmp.getvalue()} + return {'relations': base64.b64encode(tmp.getvalue())} pushkey.register('obsolete', pushobsolete, listobsolete) @@ -405,7 +407,8 @@ result = opull(remote, *args, **kwargs) if 'obsolete' in remote.listkeys('namespaces'): tmp = StringIO() - tmp.write(remote.listkeys('obsolete')['relations']) + rels = remote.listkeys('obsolete')['relations'] + tmp.write(base64.b64decode(rels)) tmp.seek(0) obsrels = _obsdeserialise(tmp) for sub, objs in obsrels.iteritems():