X-Git-Url: https://git.decadent.org.uk/gitweb/?a=blobdiff_plain;f=catherine;h=66efca2d60a8283ebc8fb501e2334e8f15daf28e;hb=1af29fa5f8b542b7cf18e2c116551f90b5b9b24d;hp=de5b6cc80b5b95173a5372176eee9b6c157f06b4;hpb=5a1b399f089fcc974943e6db92888abfe094edcc;p=dak.git diff --git a/catherine b/catherine index de5b6cc8..66efca2d 100755 --- a/catherine +++ b/catherine @@ -1,8 +1,8 @@ #!/usr/bin/env python # Poolify (move packages from "legacy" type locations to pool locations) -# Copyright (C) 2000, 2001, 2002, 2003 James Troup -# $Id: catherine,v 1.18 2003-09-07 13:52:50 troup Exp $ +# Copyright (C) 2000, 2001, 2002, 2003, 2004 James Troup +# $Id: catherine,v 1.19 2004-03-11 00:20:51 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 @@ -79,7 +79,7 @@ def poolize (q, limit, verbose, no_action): base_filename = os.path.basename(legacy_filename); destination_filename = base_filename; # Work out the source package name - if re_isadeb.match(base_filename) != None: + if re_isadeb.match(base_filename): control = apt_pkg.ParseSection(apt_inst.debExtractControl(utils.open_file(legacy_filename))) package = control.Find("Package", ""); source = control.Find("Source", package); @@ -95,7 +95,7 @@ def poolize (q, limit, verbose, no_action): destination_filename = "%s_%s_%s.deb" % (package, version, architecture); else: m = utils.re_issource.match(base_filename) - if m != None: + if m: source = m.group(1); else: utils.fubar("expansion of source filename '%s' failed." % (legacy_filename));