GNU+Linux command memo

Create a static clone of a website

Cloner un site web sur son disque dur. La copie sera gelée, on ne peut pas la mettre à jour.

To miror a website with a local static copy, the better is to use httrack :

$ httrack -n http://… (1)
$ wget -mk http://… (2)
1 The -n option tells httrack to download also "near" files, such as images linked from the HTML documents.
2 The -mk options are for -mirror and -convert-links activating all the options to create a miror website and to convert the links in the webpages to point locally to the downloaded ressources

Cloning a WordPress blog, httrack gave better results regarding CSS. Both commandes caught all the images on disk.