summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRichard Purdie <richard@openedhand.com>2007-10-11 21:42:24 +0000
committerRichard Purdie <richard@openedhand.com>2007-10-11 21:42:24 +0000
commit46b69ea92e43d0c738e60ae04a82e9c998dda94e (patch)
tree4be437a46a39439344649eb704b61b88304a0d09
parent388c2f80ffe644ad59e302c0a5803327b2880d12 (diff)
downloadopenembedded-core-46b69ea92e43d0c738e60ae04a82e9c998dda94e.tar.gz
openembedded-core-46b69ea92e43d0c738e60ae04a82e9c998dda94e.tar.bz2
openembedded-core-46b69ea92e43d0c738e60ae04a82e9c998dda94e.tar.xz
openembedded-core-46b69ea92e43d0c738e60ae04a82e9c998dda94e.zip
bitbake: Sync bzr fetcher with upstream
git-svn-id: https://svn.o-hand.com/repos/poky/trunk@2866 311d38ba-8fff-0310-9ca6-ca027cbcb966
-rw-r--r--bitbake/lib/bb/fetch/bzr.py10
1 files changed, 3 insertions, 7 deletions
diff --git a/bitbake/lib/bb/fetch/bzr.py b/bitbake/lib/bb/fetch/bzr.py
index be89a080a..c66d17fdd 100644
--- a/bitbake/lib/bb/fetch/bzr.py
+++ b/bitbake/lib/bb/fetch/bzr.py
@@ -87,7 +87,7 @@ class Bzr(Fetch):
if command is "fetch":
bzrcmd = "%s co %s %s://%s" % (basecmd, " ".join(options), proto, bzrroot)
elif command is "update":
- bzrcmd = "%s update %s" % (basecmd, " ".join(options))
+ bzrcmd = "%s pull %s --overwrite" % (basecmd, " ".join(options))
else:
raise FetchError("Invalid bzr command %s" % command)
@@ -101,8 +101,7 @@ class Bzr(Fetch):
bb.msg.debug(1, bb.msg.domain.Fetcher, "%s already exists or was mirrored, skipping bzr checkout." % ud.localpath)
return
- # Updating is disabled until bzr supports the syntax "bzr update -r X" to specify a revision
- if 0 and os.access(os.path.join(ud.pkgdir, os.path.basename(ud.pkgdir), '.bzr'), os.R_OK):
+ if os.access(os.path.join(ud.pkgdir, os.path.basename(ud.pkgdir), '.bzr'), os.R_OK):
bzrcmd = self._buildbzrcommand(ud, d, "update")
bb.msg.debug(1, bb.msg.domain.Fetcher, "BZR Update %s" % loc)
os.chdir(os.path.join (ud.pkgdir, os.path.basename(ud.path)))
@@ -145,10 +144,7 @@ class Bzr(Fetch):
output = runfetchcmd(self._buildbzrcommand(ud, d, "revno"), d, True)
- for line in output.splitlines():
- revision = line
-
- return revision
+ return output.strip()
def _sortable_revision(self, url, ud, d):
"""