Skip to content

A Portable Game Notation (PGN) ANTLR 4 grammar and parser.

License

Notifications You must be signed in to change notification settings

DennisPiskovatskov/PGN-parser

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

14 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

PGN-parser

A Portable Game Notation (PGN) ANTLR 4 grammar and parser.

The grammar can be found in src/main/antlr4/nl/bigo/pp.

Seeing the generated parser in action can be done by building a fat JAR of the project and then running it to parse a PGN file. A couple PGN files reside in src/resources.

Get started

0. Clone this repository

git clone https://github.com/DennisPiskovatskov/PGN-parser
cd PGN-parser

1. Generate the lexer and parser classes

mvn clean antlr4:antlr4

2. Build the fat JAR

mvn install package

3. Parse a PGN file

java -jar target/pp-0.1.1-SNAPSHOT.jar src/resources/Karpov.pgn

About

A Portable Game Notation (PGN) ANTLR 4 grammar and parser.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • ANTLR 60.5%
  • Java 39.5%