From 87660fb375f1c4f50b97720e3a1bde203ea4b8d9 Mon Sep 17 00:00:00 2001 From: Michael Bienia Date: Mon, 2 Nov 2009 19:03:18 +0100 Subject: [PATCH] requestsync: request syncs from 'testing' by default (should be changed back to 'unstable' for lucid+1) --- debian/changelog | 6 +++++- requestsync | 2 +- ubuntutools/requestsync/lp.py | 9 ++++++--- 3 files changed, 12 insertions(+), 5 deletions(-) diff --git a/debian/changelog b/debian/changelog index d9304b3..94678bc 100644 --- a/debian/changelog +++ b/debian/changelog @@ -26,7 +26,11 @@ ubuntu-dev-tools (0.82) UNRELEASED; urgency=low * debian/control: re-enable support for python2.5. * debian/copyright: update copyright holders. - -- Luca Falavigna Sun, 01 Nov 2009 15:58:08 +0100 + [ Michael Bienia ] + * requestsync: request syncs from 'testing' by default (should be changed + back to 'unstable' for lucid+1) + + -- Michael Bienia Mon, 02 Nov 2009 19:01:19 +0100 ubuntu-dev-tools (0.81) karmic; urgency=low diff --git a/requestsync b/requestsync index 47ce575..9febe9a 100755 --- a/requestsync +++ b/requestsync @@ -47,7 +47,7 @@ if __name__ == '__main__': optParser = OptionParser(usage) optParser.add_option('-d', type = 'string', - dest = 'dist', default = 'unstable', + dest = 'dist', default = 'testing', help = 'Debian distribution to sync from.') optParser.add_option('-k', type = 'string', dest = 'keyid', default = None, diff --git a/ubuntutools/requestsync/lp.py b/ubuntutools/requestsync/lp.py index 44f7d87..e20d0ac 100644 --- a/ubuntutools/requestsync/lp.py +++ b/ubuntutools/requestsync/lp.py @@ -29,9 +29,12 @@ def getDebianSrcPkg(name, release): debian = Distribution('debian') debian_archive = debian.getArchive() - # Map 'unstable' to 'sid' as LP doesn't know 'unstable' but only 'sid' - if release == 'unstable': - release = 'sid' + # Map 'unstable' and 'testing' to their codenames as LP knows only them + codenames = { + 'unstable': 'sid', + 'testing': 'squeeze', # Needs updating after each Debian release + } + release = codenames.get(release, release) return debian_archive.getSourcePackage(name, release)