create_sets_xml.sh now creates the correct header for sets.xml.
This commit is contained in:
parent
9dd5697213
commit
f53fff9a7b
1 changed files with 2 additions and 2 deletions
|
@ -3,8 +3,8 @@
|
|||
# Print the header
|
||||
echo '<?xml version="1.0" encoding="UTF-8"?>'
|
||||
echo '<cockatrice_setdatabase version="'`date +%Y%m%d`'">'
|
||||
echo '<picture_url>http://www.wizards.com/global/images/magic/general/%1.jpg</picture_url>'
|
||||
echo '<set_url>http://gatherer.wizards.com/Pages/Search/Default.aspx?output=spoiler&method=text&set=["!longname!"]</set_url>'
|
||||
echo '<picture_url>http://gatherer.wizards.com/Handlers/Image.ashx?multiverseid=!cardid!&type=card</picture_url>'
|
||||
echo '<set_url>http://gatherer.wizards.com/Pages/Search/Default.aspx?output=spoiler&method=text&set=["!longname!"]&special=true</set_url>'
|
||||
|
||||
# Download the sets and print them in XML
|
||||
lynx -dump -source http://magiccards.info/sitemap.html |grep Gatecrash|sed 's/<li><a href="/\n/g'|cut -f1-2 -d\>|grep ^/|sort|sed 's@/en.html">@\t@g'|sed 's@</a@@'|sed 's@^/@@' | awk 'BEGIN{ FS = "\t"}; {print "\t<set import=\"1\">\n\t\t<name>"toupper($1)"</name>\n\t\t<longname>"$2"</longname>\n\t</set>"}'
|
||||
|
|
Loading…
Reference in a new issue