From b8f923796848479e35aafebb4fb7c7be1db46ef8 Mon Sep 17 00:00:00 2001 From: James Troup Date: Tue, 20 Apr 2004 00:08:27 +0000 Subject: [PATCH] 2004-04-20 James Troup * jennifer (check_files): check for existing .changes or .katie files of the same name in the Suite::::Copy{Changes,Katie} directories. --- jennifer | 22 ++++++++++++++++++++-- 1 file changed, 20 insertions(+), 2 deletions(-) diff --git a/jennifer b/jennifer index b1193561..a3d93094 100755 --- a/jennifer +++ b/jennifer @@ -2,7 +2,7 @@ # Checks Debian packages from Incoming # Copyright (C) 2000, 2001, 2002, 2003, 2004 James Troup -# $Id: jennifer,v 1.48 2004-04-19 16:04:34 troup Exp $ +# $Id: jennifer,v 1.49 2004-04-20 00:08:27 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 @@ -47,7 +47,7 @@ re_strip_revision = re.compile(r"-([^-]+)$"); ################################################################################ # Globals -jennifer_version = "$Revision: 1.48 $"; +jennifer_version = "$Revision: 1.49 $"; Cnf = None; Options = None; @@ -323,6 +323,24 @@ def check_files(): copy_to_holding(file); os.chdir(cwd); + # Check there isn't already a .changes or .katie file of the same name in + # the proposed-updates "CopyChanges" or "CopyKatie" storage directories. + # [NB: this check must be done post-suite mapping] + base_filename = os.path.basename(pkg.changes_file); + katie_filename = base_filename[:-8]+".katie" + for suite in changes["distribution"].keys(): + copychanges = "Suite::%s::CopyChanges" % (suite); + if Cnf.has_key(copychanges) and \ + os.path.exists(Cnf[copychanges]+"/"+base_filename): + reject("%s: a file with this name already exists in %s" \ + % (base_filename, Cnf[copychanges])); + + copykatie = "Suite::%s::CopyKatie" % (suite); + if Cnf.has_key(copykatie) and \ + os.path.exists(Cnf[copykatie]+"/"+katie_filename): + reject("%s: a file with this name already exists in %s" \ + % (katie_filename, Cnf[copykatie])); + reprocess = 0; has_binaries = 0; has_source = 0; -- 2.39.2