Skip to content

Instantly share code, notes, and snippets.

@Cpleppert
Cpleppert / wget.sh
Last active October 9, 2021 02:08 — forked from Dammmien/wget.sh
wget cheat sheet
# Download all listed files within a directory and its sub-directories (does not download embedded page elements):
wget --mirror<-N<--timestamping> -r<--recursive> -l inf --no-remove-listing> --no-parent<-np> https://example.com/somepath/ -P /home/user/dirs
# Limit the download speed and the number of connection retries:
wget --limit-rate=300k --tries=100 https://example.com/somepath/
# POST a JSON file and redirect output to stdout
wget -q -O - --header="Content-Type:application/json" --post-file=foo.json http://127.0.0.1
# Download a complete website with 3-second intervals