Skip to content

Instantly share code, notes, and snippets.

@d0minicw0ng
Created February 5, 2015 12:39
Show Gist options
  • Save d0minicw0ng/2a1e5c2c4fdcac258212 to your computer and use it in GitHub Desktop.
Save d0minicw0ng/2a1e5c2c4fdcac258212 to your computer and use it in GitHub Desktop.
It is used to download a website.
# Explanation of the various flags:
# --mirror – Makes (among other things) the download recursive.
# --convert-links – convert all the links (also to stuff like CSS stylesheets) to relative, so it will be suitable for offline viewing.
# --adjust-extension – Adds suitable extensions to filenames (html or css) depending on their content-type.
# --page-requisites – Download things like CSS style-sheets and images required to properly display the page offline.
# --no-parent – When recursing do not ascend to the parent directory. It useful for restricting the download to only a portion of the site.
wget --mirror --convert-links --adjust-extension --page-requisites --no-parent http://example.org
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment