[Collab-qa-commits] r2333 - in udd: sql udd
Andreas Tille
tille at alioth.debian.org
Wed May 16 20:10:10 UTC 2012
Author: tille
Date: 2012-05-16 20:10:09 +0000 (Wed, 16 May 2012)
New Revision: 2333
Modified:
udd/sql/blends-prospective-packages.sql
udd/udd/blends_prospective_gatherer.py
Log:
Guess component of package in Vcs
Modified: udd/sql/blends-prospective-packages.sql
===================================================================
--- udd/sql/blends-prospective-packages.sql 2012-05-16 13:31:51 UTC (rev 2332)
+++ udd/sql/blends-prospective-packages.sql 2012-05-16 20:10:09 UTC (rev 2333)
@@ -15,6 +15,7 @@
long_description text,
description_md5 text,
homepage text,
+ component text,
section text,
priority text,
vcs_type text,
Modified: udd/udd/blends_prospective_gatherer.py
===================================================================
--- udd/udd/blends_prospective_gatherer.py 2012-05-16 13:31:51 UTC (rev 2332)
+++ udd/udd/blends_prospective_gatherer.py 2012-05-16 20:10:09 UTC (rev 2333)
@@ -295,7 +295,18 @@
for prop in ('homepage', 'priority', 'section', 'uploaders', ):
if src.has_key(prop):
- sprosp[prop] = src[prop]
+ if prop == 'section':
+ if src['section'].startswith('non-free'):
+ sprosp['component'] = 'non-free'
+ (dummy,sprosp['section']) = src['section'].split('/')
+ elif src['section'].startswith('contrib'):
+ sprosp['component'] = 'contrib'
+ (dummy,sprosp['section']) = src['section'].split('/')
+ else:
+ sprosp['component'] = 'main'
+ sprosp['section'] = src['section']
+ else:
+ sprosp[prop] = src[prop]
else:
sprosp[prop] = ''
if prop != 'uploaders':
@@ -345,7 +356,7 @@
changed_by, changed_by_name, changed_by_email,
uploaders,
description, long_description,
- homepage, section, priority,
+ homepage, component, section, priority,
vcs_type, vcs_url, vcs_browser,
wnpp, wnpp_type, wnpp_desc,
license, chlog_date, chlog_version)
@@ -355,10 +366,10 @@
$7, $8, $9,
$10,
$11, $12,
- $13, $14, $15,
- $16, $17, $18,
- $19, $20, $21,
- $22, $23, $24)
+ $13, $14, $15, $16,
+ $17, $18, $19,
+ $20, $21, $22,
+ $23, $24, $25)
""" % (my_config['table']))
pkgquery = """EXECUTE package_insert
(%(blend)s, %(package)s, %(source)s,
@@ -366,7 +377,7 @@
%(changed_by)s, %(changed_by_name)s, %(changed_by_email)s,
%(uploaders)s,
%(description)s, %(long_description)s,
- %(homepage)s, %(section)s, %(priority)s,
+ %(homepage)s, %(component)s, %(section)s, %(priority)s,
%(vcs_type)s, %(vcs_url)s, %(vcs_browser)s,
%(wnpp)s, %(wnpp_type)s, %(wnpp_desc)s,
%(license)s, %(chlog_date)s, %(chlog_version)s)"""
More information about the Collab-qa-commits
mailing list