#!/usr/bin/env python
# Poolify (move packages from "legacy" type locations to pool locations)
-# Copyright (C) 2000, 2001 James Troup <james@nocrew.org>
-# $Id: catherine,v 1.15 2001-11-19 02:02:53 troup Exp $
+# Copyright (C) 2000, 2001, 2002 James Troup <james@nocrew.org>
+# $Id: catherine,v 1.16 2002-05-08 11:13:02 troup Exp $
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# First move the files to the new location
pool_location = utils.poolify (source, component);
pool_filename = pool_location + destination_filename;
- destination = Cnf["Dir::PoolDir"] + pool_location + destination_filename;
+ destination = Cnf["Dir::Pool"] + pool_location + destination_filename;
if os.path.exists(destination):
utils.fubar("'%s' already exists in the pool; serious FUBARity." % (legacy_filename));
if verbose:
#!/usr/bin/env python
# 'Fix' stable to make debian-cd and dpkg -BORGiE users happy
-# Copyright (C) 2000, 2001 James Troup <james@nocrew.org>
-# $Id: claire.py,v 1.12 2001-11-19 20:42:40 rmurray Exp $
+# Copyright (C) 2000, 2001, 2002 James Troup <james@nocrew.org>
+# $Id: claire.py,v 1.13 2002-05-08 11:13:02 troup Exp $
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
for i in q.getresult():
src = i[2]+i[3]
(component, section) = fix_component_section(i[0], i[1]);
- dest = "%sdists/%s/%s/source/%s%s" % (Cnf["Dir::RootDir"], Cnf.get("Suite::Stable::CodeName", "stable"), component, section, os.path.basename(i[3]));
- src = clean_symlink(src, dest, Cnf["Dir::RootDir"]);
+ dest = "%sdists/%s/%s/source/%s%s" % (Cnf["Dir::Root"], Cnf.get("Suite::Stable::CodeName", "stable"), component, section, os.path.basename(i[3]));
+ src = clean_symlink(src, dest, Cnf["Dir::Root"]);
if not os.path.exists(dest):
if Cnf.Find("Claire::Options::Verbose"):
print src+' -> '+dest
version = utils.re_no_epoch.sub('', i[4]);
src = i[5]+i[6]
- dest = "%sdists/%s/%s/binary-%s/%s%s_%s.deb" % (Cnf["Dir::RootDir"], Cnf.get("Suite::Stable::CodeName", "stable"), component, architecture, section, package, version);
- src = clean_symlink(src, dest, Cnf["Dir::RootDir"]);
+ dest = "%sdists/%s/%s/binary-%s/%s%s_%s.deb" % (Cnf["Dir::Root"], Cnf.get("Suite::Stable::CodeName", "stable"), component, architecture, section, package, version);
+ src = clean_symlink(src, dest, Cnf["Dir::Root"]);
if not os.path.exists(dest):
if Cnf.Find("Claire::Options::Verbose"):
print src+' -> '+dest
# Add per-arch symlinks for arch: all debs
if architecture == "all":
for arch in architectures:
- dest = "%sdists/%s/%s/binary-%s/%s%s_%s.deb" % (Cnf["Dir::RootDir"], Cnf.get("Suite::Stable::CodeName", "stable"), component, arch, section, package, version);
+ dest = "%sdists/%s/%s/binary-%s/%s%s_%s.deb" % (Cnf["Dir::Root"], Cnf.get("Suite::Stable::CodeName", "stable"), component, arch, section, package, version);
if not os.path.exists(dest):
if Cnf.Find("Claire::Options::Verbose"):
print src+' -> '+dest
#!/usr/bin/env python
# Output override files for apt-ftparchive and indices/
-# Copyright (C) 2000, 2001 James Troup <james@nocrew.org>
-# $Id: denise,v 1.9 2001-11-18 19:57:58 rmurray Exp $
+# Copyright (C) 2000, 2001, 2002 James Troup <james@nocrew.org>
+# $Id: denise,v 1.10 2002-05-08 11:13:02 troup Exp $
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
################################################################################
import pg, sys, string
-import utils, db_access, natalie
+import utils, db_access
import apt_pkg;
################################################################################
projectB = pg.connect(Cnf["DB::Name"], Cnf["DB::Host"], int(Cnf["DB::Port"]));
db_access.init(Cnf, projectB);
- natalie.init();
-
for suite in [ "stable", "unstable" ]:
sys.stderr.write("Processing %s...\n" % (suite));
override_suite = Cnf["Suite::%s::OverrideCodeName" % (suite)];
override_type = ".debian-installer";
elif type == "dsc":
override_type = ".src";
- filename = "%s/override.%s.%s%s" % (Cnf["Dir::OverrideDir"], override_suite, string.replace(component, "non-US/", ""), override_type);
+ filename = "%s/override.%s.%s%s" % (Cnf["Dir::Override"], override_suite, string.replace(component, "non-US/", ""), override_type);
file = utils.open_file(filename, 'w');
sys.stdout = file;
list(suite, component, type);
#!/usr/bin/env python
# Remove obsolete .changes files from proposed-updates
-# Copyright (C) 2001 James Troup <james@nocrew.org>
-# $Id: halle,v 1.5 2002-03-31 16:14:42 troup Exp $
+# Copyright (C) 2001, 2002 James Troup <james@nocrew.org>
+# $Id: halle,v 1.6 2002-05-08 11:13:02 troup Exp $
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
file = utils.open_file(filename);
cwd = os.getcwd();
- os.chdir("%s/dists/proposed-updates" % (Cnf["Dir::RootDir"]));
+ os.chdir("%s/dists/proposed-updates" % (Cnf["Dir::Root"]));
for line in file.readlines():
line = line[:-1];
#!/usr/bin/env python
# Generate file list which is then fed to apt-ftparchive to generate Packages and Sources files
-# Copyright (C) 2000, 2001 James Troup <james@nocrew.org>
-# $Id: jenna,v 1.15 2001-11-18 19:57:58 rmurray Exp $
+# Copyright (C) 2000, 2001, 2002 James Troup <james@nocrew.org>
+# $Id: jenna,v 1.16 2002-05-08 11:13:02 troup Exp $
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
continue
if architecture == "source":
Logger.log(["Processing dists/%s/%s/%s..." % (suite, component, architecture)]);
- output = utils.open_file("%s/%s_%s_%s.list" % (Cnf["Dir::ListsDir"], suite, component, architecture), "w")
+ output = utils.open_file("%s/%s_%s_%s.list" % (Cnf["Dir::Lists"], suite, component, architecture), "w")
generate_src_list(suite, component, output, dislocated_files);
output.close();
else:
Logger.log(["Processing dists/%s/%s/binary-%s..." % (suite, component, architecture)]);
- output = utils.open_file("%s/%s_%s_binary-%s.list" % (Cnf["Dir::ListsDir"], suite, component, architecture), "w");
+ output = utils.open_file("%s/%s_%s_binary-%s.list" % (Cnf["Dir::Lists"], suite, component, architecture), "w");
generate_bin_list(suite, component, architecture, output, "deb", dislocated_files);
output.close();
if component == "main" and (suite == "unstable" or suite == "testing") and Cnf.has_key("Section::debian-installer"): # FIXME: must be a cleaner way to say debian-installer is main only?
Logger.log(["Processing dists/%s/%s/debian-installer/binary-%s..." % (suite,component, architecture)]);
- output = utils.open_file("%s/%s_%s_debian-installer_binary-%s.list" % (Cnf["Dir::ListsDir"], suite, component, architecture), "w");
+ output = utils.open_file("%s/%s_%s_debian-installer_binary-%s.list" % (Cnf["Dir::Lists"], suite, component, architecture), "w");
generate_bin_list(suite, component, architecture, output, "udeb", dislocated_files);
output.close();
Logger.close();
#!/usr/bin/env python
# Dependency check proposed-updates
-# Copyright (C) 2001 James Troup <james@nocrew.org>
-# $Id: jeri,v 1.4 2002-02-12 22:12:44 troup Exp $
+# Copyright (C) 2001, 2002 James Troup <james@nocrew.org>
+# $Id: jeri,v 1.5 2002-05-08 11:13:02 troup Exp $
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# Move to the pool directory
cwd = os.getcwd();
file = files.keys()[0];
- pool_dir = Cnf["Dir::PoolDir"] + '/' + utils.poolify(changes["source"], files[file]["component"]);
+ pool_dir = Cnf["Dir::Pool"] + '/' + utils.poolify(changes["source"], files[file]["component"]);
os.chdir(pool_dir);
changes_result = 0;
file = utils.open_file(filename);
cwd = os.getcwd();
- os.chdir("%s/dists/proposed-updates" % (Cnf["Dir::RootDir"]));
+ os.chdir("%s/dists/proposed-updates" % (Cnf["Dir::Root"]));
for line in file.readlines():
line = line[:-1];
architectures.remove(arch);
for component in components:
for architecture in architectures:
- filename = "%s/dists/%s/%s/binary-%s/Packages" % (Cnf["Dir::RootDir"], suite, component, architecture);
+ filename = "%s/dists/%s/%s/binary-%s/Packages" % (Cnf["Dir::Root"], suite, component, architecture);
packages = utils.open_file(filename, 'r');
Packages = apt_pkg.ParseTagFile(packages);
while Packages.Step():
#!/usr/bin/env python
# Handles NEW and BYHAND packages
-# Copyright (C) 2001 James Troup <james@nocrew.org>
-# $Id: lisa,v 1.8 2002-04-21 15:38:54 troup Exp $
+# Copyright (C) 2001, 2002 James Troup <james@nocrew.org>
+# $Id: lisa,v 1.9 2002-05-08 11:13:02 troup Exp $
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
import db_access, fernanda, katie, logging, utils;
# Globals
-lisa_version = "$Revision: 1.8 $";
+lisa_version = "$Revision: 1.9 $";
Cnf = None;
Options = None;
summary = summary + "Package: %s\n" % (control.Find("Package"));
summary = summary + "Description: %s\n" % (control.Find("Description"));
Katie.Subst["__BINARY_DESCRIPTIONS__"] = summary;
- bxa_mail = utils.TemplateSubst(Katie.Subst,open(Cnf["Dir::TemplatesDir"]+"/lisa.bxa_notification","r").read());
+ bxa_mail = utils.TemplateSubst(Katie.Subst,Cnf["Dir::Templates"]+"/lisa.bxa_notification");
utils.send_mail(bxa_mail,"");
################################################################################
projectB.query("COMMIT WORK");
- if Cnf.FindI("Dinstall::BXANotify"):
+ if Cnf.FindB("Dinstall::BXANotify"):
do_bxa_notification();
################################################################################
#!/usr/bin/env python
# General purpose package removal tool for ftpmaster
-# Copyright (C) 2000, 2001 James Troup <james@nocrew.org>
-# $Id: melanie,v 1.23 2002-02-22 02:19:26 troup Exp $
+# Copyright (C) 2000, 2001, 2002 James Troup <james@nocrew.org>
+# $Id: melanie,v 1.24 2002-05-08 11:13:02 troup Exp $
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
Subst["__BCC__"] = "Bcc: " + string.join(bcc, ", ");
else:
Subst["__BCC__"] = "X-Filler: 42";
- Subst["__CC__"] = "X-Melanie: $Revision: 1.23 $";
+ Subst["__CC__"] = "X-Melanie: $Revision: 1.24 $";
if carbon_copy:
Subst["__CC__"] = Subst["__CC__"] + "\nCc: " + string.join(carbon_copy, ", ");
Subst["__SUITE_LIST__"] = suites_list;
Subst["__PRIMARY_MIRROR__"] = Archive["PrimaryMirror"];
for bug in string.split(Options["Done"]):
Subst["__BUG_NUMBER__"] = bug;
- mail_message = utils.TemplateSubst(Subst,open(Cnf["Dir::TemplatesDir"]+"/melanie.bug-close","r").read());
+ mail_message = utils.TemplateSubst(Subst,Cnf["Dir::TemplatesDir"]+"/melanie.bug-close");
utils.send_mail (mail_message, "")
logfile.write("=========================================================================\n");
#!/usr/bin/env python
# Check for obsolete binary packages
-# Copyright (C) 2000, 2001 James Troup <james@nocrew.org>
-# $Id: rene,v 1.10 2002-02-12 23:14:30 troup Exp $
+# Copyright (C) 2000, 2001, 2002 James Troup <james@nocrew.org>
+# $Id: rene,v 1.11 2002-05-08 11:13:02 troup Exp $
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# along with this program; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+################################################################################
+
# "Welcome to where time stands still,
# No one leaves and no one will."
# - Sanitarium - Metallica / Master of the puppets
components = Cnf.SubTree("Suite::%s::Components" % (suite)).List();
for component in components:
- filename = "%s/dists/%s/%s/source/Sources.gz" % (Cnf["Dir::RootDir"], suite, component);
+ filename = "%s/dists/%s/%s/source/Sources.gz" % (Cnf["Dir::Root"], suite, component);
# apt_pkg.ParseTagFile needs a real file handle and can't handle a GzipFile instance...
temp_filename = tempfile.mktemp();
fd = os.open(temp_filename, os.O_RDWR|os.O_CREAT|os.O_EXCL, 0700);
for architecture in architectures:
if [ "source", "all" ].count(architecture) != 0:
continue;
- filename = "%s/dists/%s/%s/binary-%s/Packages" % (Cnf["Dir::RootDir"], suite, component, architecture);
+ filename = "%s/dists/%s/%s/binary-%s/Packages" % (Cnf["Dir::Root"], suite, component, architecture);
packages = utils.open_file(filename);
Packages = apt_pkg.ParseTagFile(packages);
while Packages.Step():
#!/usr/bin/env python
# Clean incoming of old unused files
-# Copyright (C) 2000, 2001 James Troup <james@nocrew.org>
-# $Id: shania,v 1.13 2002-03-14 14:12:04 ajt Exp $
+# Copyright (C) 2000, 2001, 2002 James Troup <james@nocrew.org>
+# $Id: shania,v 1.14 2002-05-08 11:13:02 troup Exp $
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# Move to the directory to clean
incoming = Options["Incoming"];
if incoming == "":
- incoming = Cnf["Dir::IncomingDir"];
+ incoming = Cnf["Dir::Queue::Unchecked"];
os.chdir(incoming);
# Remove a file to the morgue
#!/usr/bin/env python
# Sanity check the database
-# Copyright (C) 2000, 2001 James Troup <james@nocrew.org>
-# $Id: tea,v 1.17 2002-04-16 14:47:19 troup Exp $
+# Copyright (C) 2000, 2001, 2002 James Troup <james@nocrew.org>
+# $Id: tea,v 1.18 2002-05-08 11:13:02 troup Exp $
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
if os.access(filename, os.R_OK) == 0:
utils.warn("'%s' doesn't exist." % (filename));
- file = utils.open_file(Cnf["Dir::OverrideDir"]+'override.unreferenced');
+ file = utils.open_file(Cnf["Dir::Override"]+'override.unreferenced');
for filename in file.readlines():
filename = filename[:-1];
excluded[filename] = "";
print "Checking against existent files...";
- os.path.walk(Cnf["Dir::RootDir"]+'dists/', process_dir, None);
+ os.path.walk(Cnf["Dir::Root"]+'dists/', process_dir, None);
print
print "%s wasted..." % (utils.size_type(waste));
if component == "mixed":
continue;
component = string.lower(component);
- list_filename = '%s%s_%s_source.list' % (Cnf["Dir::ListsDir"], suite, component);
+ list_filename = '%s%s_%s_source.list' % (Cnf["Dir::Lists"], suite, component);
list_file = utils.open_file(list_filename);
for line in list_file.readlines():
file = line[:-1];