Skip to content

Instantly share code, notes, and snippets.

@genekogan
Created July 29, 2018 13:45
Show Gist options
  • Star 3 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save genekogan/cd4fc73c21a5d2816448ee5470684984 to your computer and use it in GitHub Desktop.
Save genekogan/cd4fc73c21a5d2816448ee5470684984 to your computer and use it in GitHub Desktop.
script to scrape scanned illustrations from Ernst Haeckel's book Kunstformen der Natur (Artforms of Nature)
for i in {1..100}; do
filepath=$(printf "http://caliban.mpipz.mpg.de/haeckel/kunstformen/Tafel_%03d_300.jpg" $i)
wget $filepath;
done
Copy link

ghost commented Jul 31, 2018

Hi!
I improved your script a bit.
Added hashbang to clearly indicate that it must be executed using bash and escaped variables

#! /bin/bash

for i in {1..100}; do
	filepath=$(printf "http://caliban.mpipz.mpg.de/haeckel/kunstformen/Tafel_%03d_300.jpg" "$i")
	wget "$filepath"
done

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment