Created
April 4, 2011 14:48
-
-
Save scumola/901757 to your computer and use it in GitHub Desktop.
wget lines for mirroring sites
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 characters
| #!/usr/bin/perl | |
| #Simple Perl script to save me from having to memorise the parameters. | |
| #Archives a whole website. | |
| die("Usage: archive.pl \"URL(s)\" [wait]\n") unless ($ARGV[0]); | |
| my $waitTime = 1; | |
| $waitTime = $ARGV[1] if ($ARGV[1]); | |
| system("wget --mirror --page-requisites --continue --convert-links --user-agent=\"\" -e robots=off --wait $waitTime $ARGV[0]"); |
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 characters
| #!/usr/bin/perl | |
| #Simple Perl script to save me from having to memorise the parameters. | |
| #Grabs the pages specified and converts any links between them. | |
| die("Usage: grab.pl \"URL(s)\" [wait]\n") unless ($ARGV[0]); | |
| my $waitTime = 1; | |
| $waitTime = $ARGV[1] if ($ARGV[1]); | |
| system("wget --page-requisites --continue --convert-links --user-agent=\"\" -e robots=off --wait $waitTime $ARGV[0]"); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment