Created
July 10, 2013 16:29
-
-
Save JustinAzoff/5967817 to your computer and use it in GitHub Desktop.
Simple script that uses wget to download a usable copy of every RT ticket in HTML form. useful for disabling the web application but maintaining access to all ticket information in the standard format.
This file contains 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
#!/bin/zsh | |
URL=$1 | |
MAX=$2 | |
echo -ne "User: " | |
read user | |
echo -ne "PW: " | |
read pw | |
wget --no-check-certificate --keep-session-cookies --save-cookies cookies.txt $URL/search/ticket?id=1 --post-data "user=$user&pass=$pw" -O/dev/null | |
wget --no-check-certificate --load-cookies cookies.txt --convert-links -p "$URL/Ticket/Display.html?id="{1..$MAX} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment