diff options
author | Dan McGee <dan@archlinux.org> | 2011-08-16 14:39:23 -0500 |
---|---|---|
committer | Dan McGee <dan@archlinux.org> | 2011-08-16 14:39:41 -0500 |
commit | f7626c05719ebb4362836d2ba7e1d297bd8a92a6 (patch) | |
tree | 5d79a4e049b5460def3a651ebe7503becd3495c8 /releng/management/commands/syncisos.py | |
parent | 110c79ad0637c8e35b18c9ccc201d33d456d5453 (diff) |
Add a removed date for releng ISOs
Signed-off-by: Dan McGee <dan@archlinux.org>
Diffstat (limited to 'releng/management/commands/syncisos.py')
-rw-r--r-- | releng/management/commands/syncisos.py | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/releng/management/commands/syncisos.py b/releng/management/commands/syncisos.py index ba174131..23955afe 100644 --- a/releng/management/commands/syncisos.py +++ b/releng/management/commands/syncisos.py @@ -1,3 +1,4 @@ +from datetime import datetime import re import urllib from HTMLParser import HTMLParser, HTMLParseError @@ -45,7 +46,9 @@ class Command(BaseCommand): if iso not in isonames: new = Iso(name=iso, active=True) new.save() + now = datetime.utcnow() # and then mark all other names as no longer active - Iso.objects.exclude(name__in=active_isos).update(active=False) + Iso.objects.filter(active=True).exclude(name__in=active_isos).update( + active=False, removed=now) # vim: set ts=4 sw=4 et: |