Created
May 1, 2018 12:34
-
-
Save tdtgit/ad37a81e60cf07a61c867019109c85c4 to your computer and use it in GitHub Desktop.
Revisions
-
tdtgit created this gist
May 1, 2018 .There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,21 @@ #!/bin/bash # # Written by AC - 2015 <[email protected]> - sys0dm1n.com # URL=$1 wget --quiet http://$URL/sitemap.xml --no-cache --output-document - | egrep -o "http(s?)://$URL[^ \"\'()\<>]+" | while read line; do if [[ $line == *.xml ]] then newURL=$line wget --quiet $newURL --no-cache --output-document - | egrep -o "http(s?)://$URL[^ \"\'()\<>]+" | while read newline; do curl -s -S -H "accept-encoding: gzip, deflate, br" -A 'Cache Warmer' -sL $newline -o /dev/null 2>&1 # echo $newline done else curl -s -S -H "accept-encoding: gzip, deflate, br" -A 'Cache Warmer' -sL $line -o /dev/null 2>&1 # echo $line fi done echo "Done $URL"; exit