openmamba-release/openmamba-smart-milestone4.py

124 lines
4.2 KiB
Python
Raw Normal View History

2016-09-11 10:49:40 +02:00
#
# openmamba milestone4 channel configuration for Smart Package Manager
#
if not sysconf.get(("channels", "milestone4")):
sysconf.set(("channels", "milestone4"),
{"alias": "milestone4",
"type": "apt-rpm",
"name": "stable milestone4 base packages",
"baseurl": "http://cdn.openmamba.org/pub/openmamba/milestone4",
"components": "%ARCH%"})
#
# openmamba milestone4-games channel configuration for Smart Package Manager
#
if not sysconf.get(("channels", "milestone4-games")):
sysconf.set(("channels", "milestone4-games"),
{"alias": "milestone4-games",
"type": "apt-rpm",
"name": "stable milestone4 games packages",
"baseurl": "http://cdn.openmamba.org/pub/openmamba/milestone4-games",
"components": "%ARCH%"})
#
# openmamba milestone4-updates channel configuration for Smart Package Manager
#
if not sysconf.get(("channels", "milestone4-updates")):
sysconf.set(("channels", "milestone4-updates"),
{"alias": "milestone4-updates",
"type": "apt-rpm",
"name": "stable milestone4 updates packages",
"baseurl": "http://cdn.openmamba.org/pub/openmamba/milestone4-updates",
"components": "%ARCH%"})
#
# openmamba milestone4-kernel channel configuration for Smart Package Manager
#
if not sysconf.get(("channels", "milestone4-kernel")):
sysconf.set(("channels", "milestone4-kernel"),
{"alias": "milestone4-kernel",
"type": "apt-rpm",
"name": "newest kernel release for milestone4 stable systems",
"baseurl": "http://cdn.openmamba.org/pub/openmamba/milestone4-kernel",
"components": "%ARCH%",
"disabled": "yes"})
#
# openmamba milestone4-kernel-next channel configuration for Smart Package Manager
#
if not sysconf.get(("channels", "milestone4-kernel-next")):
sysconf.set(("channels", "milestone4-kernel-next"),
{"alias": "milestone4-kernel-next",
"type": "apt-rpm",
"name": "experimental kernel release for milestone4 stable systems",
"baseurl": "http://cdn.openmamba.org/pub/openmamba/milestone4-kernel-next",
"components": "%ARCH%",
"disabled": "yes"})
#
# openmamba milestone4-kde4 channel configuration for Smart Package Manager
#
if not sysconf.get(("channels", "milestone4-kde4")):
sysconf.set(("channels", "milestone4-kde4"),
{"alias": "milestone4-kde4",
"type": "apt-rpm",
"name": "newest kde4 release for milestone4 stable systems",
"baseurl": "http://cdn.openmamba.org/pub/openmamba/milestone4-kde4",
"components": "%ARCH%",
"disabled": "yes"})
#
# openmamba milestone4-xorg channel configuration for Smart Package Manager
#
if not sysconf.get(("channels", "milestone4-xorg")):
sysconf.set(("channels", "milestone4-xorg"),
{"alias": "milestone4-xorg",
"type": "apt-rpm",
"name": "newest X.org release for milestone4 stable systems",
"baseurl": "http://cdn.openmamba.org/pub/openmamba/milestone4-xorg",
"components": "%ARCH%",
"disabled": "yes"})
#
# openmamba milestone4-makedist channel configuration for Smart Package Manager
#
if not sysconf.get(("channels", "milestone4-makedist")):
sysconf.set(("channels", "milestone4-makedist"),
{"alias": "milestone4-makedist",
"type": "apt-rpm",
"name": "experimental milestone4 makedist packages",
"baseurl": "http://cdn.openmamba.org/pub/openmamba/milestone4-makedist",
"components": "%ARCH%",
"disabled": "yes"})
import os
import sys
release=os.popen("openmamba-release -c").read()
for r in ["milestone4","milestone4-updates","milestone4-games","milestone4-makedist","milestone4-kernel","milestone4-kde4","milestone4-xorg","milestone4-kernel-next"]:
channel=sysconf.get(("channels", r))
if channel:
if channel['baseurl'].startswith('http://www.openmamba.org/'):
channel['baseurl'] = \
channel['baseurl'].replace('http://www.openmamba.org/','http://cdn.openmamba.org/')
channel['fingerprint']='A402 AA41 82DE 06DD 0C82 943A B771 C004 8746 8781'
sysconf.set(("channels",r),channel)
if release.startswith('milestone4'):
for r in ["milestone4","milestone4-updates","milestone4-games"]:
channel=sysconf.get(("channels", r))
if channel:
channel['disabled']=False
sysconf.set(("channels",r),channel)
for r in ["devel","devel-games"]:
channel=sysconf.get(("channels", r))
if channel:
channel['disabled']=True
sysconf.set(("channels",r),channel)