Metadata-Version: 2.1
Name: pgn-read
Version: 2.3.1
Summary: Portable Game Notation (PGN) parser.
Author-email: Roger Marsh <roger.marsh@solentware.co.uk>
License: Licence for pgn package
        Copyright (c) 2009, Roger Marsh
        All rights reserved.
        
        Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:
        
        
        Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.
        
        Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.
        
        Neither the name of the owner nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission.
        
        
        THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
        
Project-URL: Homepage, http://www.solentware.co.uk
Project-URL: Repository, https://github.com/RogerMarsh/pgn-read.git
Project-URL: Bug Tracker, https://github.com/RogerMarsh/pgn-read/issues
Classifier: License :: OSI Approved :: BSD License
Classifier: Programming Language :: Python :: 3.7
Classifier: Programming Language :: Python :: 3.8
Classifier: Programming Language :: Python :: 3.9
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Operating System :: OS Independent
Classifier: Topic :: Software Development
Classifier: Topic :: Games/Entertainment :: Board Games
Classifier: Intended Audience :: Developers
Classifier: Development Status :: 3 - Alpha
License-File: LICENCE

===================================
Portable Game Notation (PGN) parser
===================================

.. contents::


Description
===========

This package provides a parser for chess game scores in `PGN`_ format.

Both the strict export format and many less strict import formats are supported.

Chess variants are not supported.

The game module provides the Game, GameStrictPGN, GameTextPGN, and GameIgnoreCasePGN, classes and the generate_fen_for_position function.

The parser module provides the PGN class and add_token_to_game function.

The PGN.read_games method yields instances of the Game class, or a subclass, generated from a file-like source or string.

The add_token_to_game function searches for the next PGN token in a string and applies it to an instance of the Game class, or a subclass.

The generate_fen_for_position function returns the Forsyth English Notation (FEN) string for the representation of a position in the Game class, or a subclass.


Installation Instructions
=========================

This package is available on PyPI so can be installed by typing

   python -m pip install --user pgn-read

at the command prompt.

See `Python`_ and `pip`_ documentation for alternatives and platform-specific points.


Tests
=====

Tests are available at the `repository`_ in the pgn_read.core.tests sub-package.

Copy the tests directory and run tests by typing, for example,

   python -m pgn_read.core.tests.test_squares

at the command prompt with setup.py in the current directory.


Notes
=====

Project name and package name changed from 'pgn' to 'pgn-read' prior to upload to PyPI.

The version numbers of pgn-read continue on from pgn.

The pgn_read.core.tests sub-package was removed from the distribution created by setup when the `repository`_ was created.


.. _Python: https://python.org
.. _pip: https://packaging.python.org/installing
.. _PGN: https://www.chessclub.com/help/PGN-spec
.. _repository: https://github.com/RogerMarsh/pgn-read
