X-Git-Url: http://mj.ucw.cz/gitweb/?a=blobdiff_plain;f=bin%2Fmo-score;h=4fce9e44be5f9aa32e21c6a344c5d05b88b692bd;hb=d2c47625c8b5e7392c95d63b7f1a13e492d053f7;hp=358b20ac29380a4a8945eb9951b6f04050595585;hpb=67625d9baadd2fcafc37090976a7b781591b8938;p=eval.git diff --git a/bin/mo-score b/bin/mo-score index 358b20a..4fce9e4 100755 --- a/bin/mo-score +++ b/bin/mo-score @@ -15,6 +15,8 @@ while (($arg = $ARGV[0]) =~ /^--([a-z]+)$/) { } @ARGV || die $usage; +@tasks = @ARGV; + print STDERR "Scanning contestants... "; open (CT, "bin/mo-get-users --full |") || die "Cannot get list of contestants"; while () { @@ -183,15 +185,18 @@ if ($debug) { print '', "\n"; print "Rank list\n"; print "

Rank list

\n"; - print "\n"; - $hdr = 1; - foreach $r (@table) { - print "", join('',map { - if ($hdr) { $_ = ""; + + foreach $r (@table[1..($#table - 1)]) { + &printHtmlRow(@{$r}[@perm]); } + + print ""; + &printHtmlRow(@{$table[$#table]}[@perm]); + print "
$_"; } - else { $_ = " 14 ? " width=150" : "") . ">$_"; } - } @$r), "\n"; - $hdr = 0; + + my @perm; + &printHtmlHeader(\@perm); + print "
\n"; if ($detail) { print "

Error codes