Metadata-Version: 2.1
Name: pgnsplit
Version: 0.1.2
Summary: Simple package that splits a chess pgn file into a folder of pgns - each one containing one variation of the original pgn.
Home-page: https://github.com/vsingh18567/pgn-split
License: MIT
Keywords: Chess,CLI,PGN
Author: vsingh18567
Author-email: vsingh18567@gmail.com
Requires-Python: >=3.8,<4.0
Classifier: License :: OSI Approved :: MIT License
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.8
Classifier: Programming Language :: Python :: 3.9
Requires-Dist: chess (>=1.6.1,<2.0.0)
Requires-Dist: click (>=8.0.1,<9.0.0)
Project-URL: Repository, https://github.com/vsingh18567/pgn-split
Description-Content-Type: text/markdown

# pgnsplit

`pgnsplit` is a simple command-line application that takes a single [pgn](https://en.wikipedia.org/wiki/Portable_Game_Notation) file (e.g. from a [Lichess Study](https://lichess.org/study/KjivNw7F)) and extracts all the variations in the pgn, putting each of them in their own individual pgn files in a folder `./pgn/`, which can then be stored in some sort of database (e.g. in SCID or ChessX).

This solves the problem in various chess software, where importing pgns only stores the mainline variation. 

This is presented as a lightweight and easy-to-use alternative to [David J. Barnes' pgn-extract](https://www.cs.kent.ac.uk/people/staff/djb/pgn-extract/help.html), which is still more appropriate for the intricate manipulation of pgn files. 

## Requirements
* Python (>3.8)
* pip (which normally comes with Python)

## Installation
```bash
$ pip install pgnsplit
```

## Usage
```bash
$ pgnsplit <filepath>
```
`<filepath>` must be the path to a properly formatted pgn file. The individual pgn files will be stored in a local folder. 

## Improvements
Further improvements/functionality could be made as requested/needed.
