added check_rarity rule

master
melvin 2013-07-17 21:00:32 +08:00
parent 51c7c27d81
commit ab00e79ac5
2 changed files with 8 additions and 2 deletions

View File

@ -448,7 +448,13 @@ checks: \
check_groovy_escape \
check_url \
check_image \
check_meta
check_meta \
check_rarity
# check rarity using meta.xml
check_rarity: scripts/fix_rarity.scala cards/meta.xml
cat release/Magarena/scripts/*.txt | scala $^ | grep -v "not be L" | grep -v "Windseeker Centaur" | ${NO_OUTPUT}
# check metadata using cards.xml
check_meta: cards/scriptable.txt

View File

@ -68,7 +68,7 @@ for (line <- Source.stdin.getLines) {
if ((name2card(curr_name) \\ "rarity").exists(x => x.text.charAt(0) == curr_rarity)) {
//Console.err.println("found")
} else {
Console.err.println(curr_name + "'s rarity should not be " + curr_rarity)
Console.out.println(curr_name + "'s rarity should not be " + curr_rarity)
}
}
}