NAME

Chess::Games::DotCom - API for accessing chessgames.com

SYNOPSIS

shell> perl -MChess::Games::DotCom -e  game_of_day
shell> perl -MChess::Games::DotCom -e 'game_of_day("myfile.pgn")'

shell> perl -MChess::Games::DotCom -e  puzzle_of_day
shell> perl -MChess::Games::DotCom -e 'puzzle_of_day("myfile.pgn")'

ABSTRACT

Download games from chessgames.com.

A script in scripts suitable for invocation from cron is included.

API

game_of_day [ $filename ]

Downloads the game of the day. If $filename is not specified, then it downloads it to game_of_day.pgn.

puzzle_of_day [ $filename ]

Downloads the puzzle of the day. If $filename is not specified, then it downloads it to puzzle_of_day.pgn.

EXPORT

game_of_day puzzle_of_day

NEW FEATURES

in 0.09

Realized that I parsed out the wrong thing and parsed out something like:

12. ...?

instead.

Stored this in plycount instead.

in 0.08

For puzzle_of_day(), parsed out "$color to move and win" and stored in the PlyCount header of PGN so that I could see where the puzzle began.

Too see an example of a log of auto-downloaded games, visit:

http://princepawn.perlmonk.org/chess/pgn/montreux.html

in 0.07

Added a sample cron file for daily automatic retrieval of puzzle of day.

Added Log::Agent logging to sample retrieval script

in 0.06

puzzle_of_day was added

TODO

Download other daily game parts of the site

RESOURCES

The Perl Chess Mailing List:

http://www.yahoogroups.com/group/perl-chess

AUTHOR

T. M. Brannon, <tbone@cpan.org>

INSTALLATION

You must have the following installed:

1 URI
2 Bundle::LWP
3 HTML::Tree

Optional

For the script in the scripts directory, you also need:

4 File::Butler
5 File::Temp
6 Log::Agent

COPYRIGHT AND LICENSE

Copyright 2003 by T. M. Brannon

This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself.

2 POD Errors

The following errors were encountered while parsing the POD:

Around line 257:

Non-ASCII character seen before =encoding in '12. ...?'. Assuming CP1252

Around line 327:

You forgot a '=back' before '=head1'