improve regex to extract deck ids

master
melvin 2014-01-01 21:50:49 +08:00
parent f7f7d9e08a
commit e1455d71e1
1 changed files with 1 additions and 1 deletions

View File

@ -275,7 +275,7 @@ decks/mtgtop8_%.dec:
wget "http://www.mtgtop8.com/export_files/deck$*.mwDeck" -O $@
decks/update:
$(eval LAST := $(shell curl http://mtgtop8.com/search | grep "d=[0-9]\+" -o | sort | tail -1 | sed 's/d=//'))
$(eval LAST := $(shell curl http://mtgtop8.com/search | grep "&d=[0-9]\+" -o | sort | tail -1 | sed 's/&d=//'))
-seq `expr ${LAST} - 200` ${LAST} | parallel make decks/mtgtop8_{}.dec
find decks -size 0 -delete