From: Eric S. Raymond Date: Wed, 20 Oct 2010 11:06:51 +0000 (-0400) Subject: Delete URLs not in update list (untested). X-Git-Tag: 2.1~13 X-Git-Url: http://thyrsus.com/gitweb/?a=commitdiff_plain;h=8af6851fe92c293de63a8d891fb95127892316a6;p=freecode-submit.git Delete URLs not in update list (untested). --- diff --git a/freshmeat-submit b/freshmeat-submit index e131afb..f226649 100755 --- a/freshmeat-submit +++ b/freshmeat-submit @@ -153,12 +153,11 @@ class FreshmeatSession: "POST", {"url" : {"label": label, "location" : url}}) # Delete URLs that weren't in the update list - # FIXME: This cannot work yet: there's no auth code! remove = set(permadict.keys()) - set(lambda x: x[0], urlassoc) - #for label in remove: - # self.edit_request("projects/%s/urls/%s.json" - # % (self.permalink, permadict[label]), - # "DELETE") + for label in remove: + self.edit_request("projects/%s/urls/%s.json?auth_code=%s" + % (self.permalink, permadict[label], self.auth), + "DELETE") class FreshmeatMetadataFactory: "Factory class for producing Freshmeat records in JSON." freshmeat_field_map = (