Grimoire-
Command
.es

GNU+Linux command memo

Download a file selection via wget or doc_crawler.py

Télécharger une sélection de fichiers via wget ou doc_crawler.py

$ wget --recursive --limit 1 http://… (1)

$ wget --recursive http://a.eu/p/ --no-directories --directory-prefix $d --accept JPG,JPEG (2)

$ wget http://a.eu/photos/{001..146}.jpg (3)

$ wget http://imgs.xkcd.com/clickdrag/{1..50}{n,s}{1..50}{w,e}.png (4)

$ wget --recursive --no-parent --wait 5 --random-wait --domains ${a.eu} --no-clobber http://a.eu (5)
$ wget -r -np -w 5 --random-wait -D ${a.eu} -nc http://a.eu (5)

$ doc_crawler.py --download http://a.eu (6)

$ wget --recursive --no-parent --wait 5 --random-wait --convert-links --page-requisites --domains ${a.eu} --no-clobber http://a.eu (7)
$ wget -r -np -w 5 --random-wait -k -p -D ${a.eu} -nc http://a.eu (7)
1 Download all what wget finds one link away
2 Download all the JPG or JPEG photos from a web gallery
3 Download a series of photos. Series work everywhere : cp DSCN0{753..833}.JPG img/
4 Download all the tiles from XKCD 1110 "Click and Drag" ; please don’t be rude
5 Download all a website, and avoid being banned going too fast
6 Same as above but only files are downloaded (PDF, ODT, ZIP…). More info here.
7 Downloand a full website to read it offline later, won’t download twice the same files if the operation is interrupted and restarted.