hostname_url) = remaining_args except: print "Usage: ./mk-distro-index.py [--skip_zip] <bundle name> <output webdir> <webroot_path> <package source dir> <hostname_url>" print " --platforms: comma separated list of platforms (distros) to include" sys.exit(1) skip_zip = False for option, value in opts: if option == "--skip_zip": skip_zip = True # override distro list if option == "--platforms": distros = value.split(",") bundle_conf = packaging.bundle(bundle_name=bundle) url_prefix = 'download-' + bundle_conf.info['bundle_urlname'] # Get a short description, if there is one bundle_short_desc = bundle_conf.info['bundle_urlname'] if bundle_conf.info.has_key('bundle_short_desc'): bundle_short_desc = bundle_conf.info['bundle_short_desc'] fd = open(os.path.join(config.release_repo_root, 'website', 'distro-index')) template = fd.readlines() fd.close() version = bundle_conf.info['archive_version'] package_src_url = os.path.basename(package_src_dir) if not package_src_url:
#!/usr/bin/env python import sys import pdb sys.path.append("../pyutils") import packaging bundle_conf = packaging.bundle(bundle_name='1.1.13') for i in ['gtk-sharp', 'gtk-sharp-2.0', 'gtk-sharp-2.8']: env = packaging.buildenv('suse-101-i586') pack = packaging.package( env, i, bundle_obj=bundle_conf, source_basepath='/var/www/mono-website/go-mono/sources', package_basepath='/var/www/mono-website/go-mono/download') print "\n".join(pack.get_files()) print pack.get_source_file()
print " --skip_obs_repos will not download obs repos" print " --skip_missing will allow missing packages for a various platform" print " --platforms: comma separated list of platforms (distros) to sync" print " Ex: ./sync-bundle.py RELEASE wblinux.provo.novell.com:wa/msvn/release/packaging" sys.exit(1) pack_map = {} files = [] rpms = [] dirs = [] sources = [] execfile('repo-config/config.py') # (for packages_in_repo) bundle_obj = packaging.bundle(bundle_name=bundle_name) def find_base_distro(pack_name, distro_name): """Look at all the build hosts to see which gives the same distro_root""" plat_obj = packaging.buildconf(distro_name, exclusive=False) pack_obj = packaging.package(plat_obj, pack_name, bundle_obj=bundle_obj) target_base_path = pack_obj.package_relpath base_distro = "" for p in pack_obj.get_info_var("BUILD_HOSTS"): plat2 = packaging.buildconf(p, exclusive=False) pack2 = packaging.package(plat2, pack_name, bundle_obj=bundle_obj)
import pdb sys.path += [ '../pyutils' ] import shell_parse import packaging import config # Command line options try: (script_name, bundle, output_dir, sources_dir) = sys.argv except: print "Usage: ./mk-sources-index.py <bundle name> <output webdir> <sources_dir>" sys.exit(1) bundle_conf = packaging.bundle(bundle_name=bundle) # Create url dirs distutils.dir_util.mkpath(output_dir + os.sep + "sources-" + bundle_conf.info['bundle_urlname']) distutils.dir_util.mkpath(os.path.join(output_dir, "archive", bundle_conf.info['archive_version'], 'sources')) out = open(os.path.join(output_dir, 'sources-' + bundle_conf.info['bundle_urlname'], 'index.html'), 'w') arc_out = open(os.path.join(output_dir, 'archive', bundle_conf.info['archive_version'], 'sources', 'index.html'), 'w') fd = open(os.path.join(config.release_repo_root, 'website', 'sources-index')) template = fd.readlines() fd.close() for line in template: line_items = line.split() if line_items and line_items[0] == "#":
print " --skip_missing will allow missing packages for a various platform" print " --platforms: comma separated list of platforms (distros) to sync" print " Ex: ./sync-bundle.py RELEASE wblinux.provo.novell.com:wa/msvn/release/packaging" sys.exit(1) pack_map = {} files = [] rpms = [] dirs = [] sources = [] execfile('repo-config/config.py') # (for packages_in_repo) bundle_obj = packaging.bundle(bundle_name=bundle_name) def find_base_distro(pack_name, distro_name): """Look at all the build hosts to see which gives the same distro_root""" plat_obj = packaging.buildconf(distro_name, exclusive=False) pack_obj = packaging.package(plat_obj, pack_name, bundle_obj=bundle_obj) target_base_path = pack_obj.package_relpath base_distro = "" for p in pack_obj.get_info_var("BUILD_HOSTS"): plat2 = packaging.buildconf(p, exclusive=False) pack2 = packaging.package(plat2, pack_name, bundle_obj=bundle_obj) if pack2.package_relpath == target_base_path:
#!/usr/bin/env python import sys import pdb sys.path.append("../pyutils") import packaging bundle_conf = packaging.bundle(bundle_name='1.1.13') for i in ['gtk-sharp', 'gtk-sharp-2.0', 'gtk-sharp-2.8']: env = packaging.buildenv('suse-101-i586') pack = packaging.package(env, i, bundle_obj=bundle_conf, source_basepath='/var/www/mono-website/go-mono/sources', package_basepath='/var/www/mono-website/go-mono/download') print "\n".join(pack.get_files()) print pack.get_source_file()