Thanks to visit codestin.com
Credit goes to github.com

Skip to content

A Ruby library to parse SGF (Smart Game Format) files, best-known for holding weiqi / go game records

License

Notifications You must be signed in to change notification settings

amikula/SGFParser

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

15 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Example: require ‘sgfparser’ tree = SGF::Tree.new :filename => File tree = SGF::Tree.new :sgf_string => String

Should work with all FF4 files (in fact, all SGF files, but did not test any files with a format pre-FF4). Should also work with Ruby from 1.8.6 and up, though untested with anything earlier than 1.8.7.

The ‘SGF Indenter’, the purpose of which is to make the actual SGF file more human readable, is working.

Files can be saved. There is an error in the saving test, which I don’t understand, but… It’s working as far as I can tell. I need to write more detailed tests, I think.

_

TODO ? Create a “Game” class, and if a whole set of () exists, then I have a game? That way maybe I can easily go to multiple games stored in a single SGF file? Mostly syntactic sugar, but may be worth implementing.

About

A Ruby library to parse SGF (Smart Game Format) files, best-known for holding weiqi / go game records

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Ruby 100.0%