X-Git-Url: https://git.decadent.org.uk/gitweb/?a=blobdiff_plain;f=shania;h=7497b630530664149282a26075729788fe9eaf55;hb=9ba8cd630711928ad4bd0208a59f1afc04eb3ffb;hp=b12fb0ab766d084a89365469c02bfe7b2a0822bf;hpb=e8eacb00ee41d7ab974ba913fff40e5c082b8e1a;p=dak.git diff --git a/shania b/shania index b12fb0ab..7497b630 100755 --- a/shania +++ b/shania @@ -1,8 +1,8 @@ #!/usr/bin/env python # Clean incoming of old unused files -# Copyright (C) 2000 James Troup -# $Id: shania,v 1.1 2000-12-13 03:18:50 troup Exp $ +# Copyright (C) 2000, 2001 James Troup +# $Id: shania,v 1.3 2001-03-02 02:43:49 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 @@ -93,7 +93,7 @@ def main (): # Proces all .changes and .dsc files. for changes_filename in changes_files: try: - changes = utils.parse_changes(changes_filename) + changes = utils.parse_changes(changes_filename, 0) except: continue; try: @@ -105,7 +105,7 @@ def main (): for file in files.keys(): if re_isdsc.search(file) != None: try: - dsc = utils.parse_changes(file) + dsc = utils.parse_changes(file, 0) except: continue; try: @@ -173,10 +173,12 @@ Debian distribution maintenance software print "Sent reminder email to %s." % (changes["maintainer822"]); else: # Ensure the files aren't deleted - for keys in (files.keys(), dsc_files.keys(), changes_filename): - for i in keys: - if all_files.has_key(i): - del all_files[i]; + keys = []; + for i in (files.keys(), dsc_files.keys(), [changes_filename]): + keys.extend(i); + for key in keys: + if all_files.has_key(key): + del all_files[key]; # Anthing left at this stage is not referenced by a .changes or # .dsc and should be deleted if old enough.