gnuchess/genbook.sh
Dirk Stoecker 884267f62b Accepting request 94250 from home:jreidinger:branches:games
- update gnuchess to official version 6.0.1
- clean up patches
- change generation of recent book dat from source during build

OBS-URL: https://build.opensuse.org/request/show/94250
OBS-URL: https://build.opensuse.org/package/show/games/gnuchess?expand=0&rev=6
2011-12-01 07:36:10 +00:00

27 lines
503 B
Bash

#! /bin/sh
echo -e "\nPreparing data...\n"
bzcat $1 >book.pgn
#head -30000 book.pgn >smallbook.pgn
echo -e "\nDone."
#echo -e "\nGenerating smallbook...\n"
#src/gnuchess <<EOF
#book add smallbook.pgn
#quit
#EOF
#mv book.dat smallbook.dat
#echo -e "\nDone.\n"
echo -e "\nGenerating book...\n"
expect <<EOF
set timeout 360
spawn src/gnuchess
expect "White" { send "book add book.pgn\n" }
expect "all done!" { send "quit\n" }
EOF
mv -v book.bin src/book.bin
echo -e "\nDone.\n"
echo "Books are ready!"