Skip to content

Instantly share code, notes, and snippets.

@travis-g
Created October 30, 2018 15:12
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save travis-g/8e7c00269dce188b48ad7615dadecf30 to your computer and use it in GitHub Desktop.
Save travis-g/8e7c00269dce188b48ad7615dadecf30 to your computer and use it in GitHub Desktop.
recursive wget to check sites for broken links/dependencies
#!/bin/bash
if [A "$2" -eq "-v" ]; then
wget --recurive --delete-after "$1"
else
wget \
--spider \
--recursive \
--delete-after \
--level inf \
--no-directories \
--no-host-directories \
--no-verbose \
--page-requisites \
"$1"
fi
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment