Skip to content
Browse files

This script download a series of screenshots made by OSdir.

  • Loading branch information...
1 parent 8e7a97f commit 0639453e723d9377da48c7cc9e13e6834d356d7c @kdeldycke committed Apr 4, 2005
Showing with 21 additions and 0 deletions.
  1. +21 −0 osdir-slideshow.py
View
21 osdir-slideshow.py
@@ -0,0 +1,21 @@
+#!/usr/bin/python
+
+from os import system
+from commands import getstatusoutput
+
+
+if __name__ == "__main__":
+
+ to_download = [ (147, 101)
+ , (50, 27)
+ , (140, 41)
+ , (155, 105)
+ ]
+
+ for (product, slide_nb) in to_download:
+ system("mkdir ./" + str(product))
+ for slide_id in range(slide_nb):
+ url = "http://osdir.com/shots/slideshows/" + str(product) + "/" + str(slide_id + 1) + ".gif"
+ result = getstatusoutput("wget -P ./" + str(product) + "/ " + url)
+ print " * Downloaded : " + url
+ # rename here 1.gif to 01.gif (and 20.gif to 020.gif) if needed

0 comments on commit 0639453

Please sign in to comment.
Something went wrong with that request. Please try again.