Web   ·   Wiki   ·   Activities   ·   Blog   ·   Lists   ·   Chat   ·   Meeting   ·   Bugs   ·   Git   ·   Translate   ·   Archive   ·   People   ·   Donate
summaryrefslogtreecommitdiffstats
path: root/modules
diff options
context:
space:
mode:
authorDaniel Drake <dsd@laptop.org>2011-10-06 11:38:11 (GMT)
committer Anish Mangal <anish@activitycentral.com>2012-01-30 17:47:58 (GMT)
commitb72ca565d7ead38cf8c09000d8d243e2e9339cd1 (patch)
tree68b6c2b8abcdff125331899713ff732fe4890d72 /modules
parent5bfc5bedec9fe4fe22ca0df03b327e0c48f9ab84 (diff)
repos: fix hyphen/underscore confusion
Koji repos use hyphens and it wouldn't be a good idea to rename them all. So restrict the hyphen-to-underscore conversion for compatibility with Fedora repo names only.
Diffstat (limited to 'modules')
-rw-r--r--modules/repos/ksmain.50.repos.py13
1 files changed, 11 insertions, 2 deletions
diff --git a/modules/repos/ksmain.50.repos.py b/modules/repos/ksmain.50.repos.py
index e1dee21..c6b3872 100644
--- a/modules/repos/ksmain.50.repos.py
+++ b/modules/repos/ksmain.50.repos.py
@@ -31,9 +31,18 @@ def add_to_excludes(baseurl, addexcludes):
# clean up addexcludes list
if addexcludes is not None:
- addexcludes = addexcludes.replace('-', '_').split(',')
+ addexcludes = addexcludes.split(',')
for idx, excl in enumerate(addexcludes):
- addexcludes[idx] = excl.strip()
+ excl = excl.strip()
+
+ # Support hyphenated fedora repo notation, as this matches the
+ # default files in /etc/yum.repos.d
+ if excl == 'fedora-updates-testing':
+ excl = 'fedora_updates_testing'
+ elif excl == 'fedora-updates':
+ excl = 'fedora_updates'
+
+ addexcludes[idx] = excl
else:
addexcludes = []