OSDN Git Service

[shogi-server] Bump up the revision to 20201206
[shogi-server/shogi-server.git] / mk_rate
diff --git a/mk_rate b/mk_rate
index f2c24c6..0e67375 100755 (executable)
--- a/mk_rate
+++ b/mk_rate
 # * (Rated) players, who played more than $GAMES_LIMIT [15] (rated) games. 
 #
 
-$:.unshift(File.dirname(File.expand_path(__FILE__)))
+require 'pathname'
+$:.unshift(File.dirname(Pathname.new(__FILE__).realpath))
 require 'utils/csa-filter'
 require 'yaml'
 require 'time'
@@ -671,7 +672,7 @@ def parse(line)
   end
   $history.add line
 
-  time, state, black_mark, black_id, white_id, white_mark, file = line.split("\t")
+  time, state, black_mark, black_id, white_id, white_mark, file, moves = line.split("\t")
   unless time && state && black_mark && black_id &&
          white_id && white_mark && file
     $stderr.puts "Failed to parse the line : #{line}"