/cobol_parser

cobol_parser is a COBOL parser written in pure ruby. It outputs s-expressions which like whitequark/parser's outputs.

Primary LanguageRubyGNU General Public License v2.0GPL-2.0

cobol_parser

cobol_parser is a COBOL parser written in pure ruby. It outputs s-expressions which like whitequark/parser's outputs. So you can translate COBOL to Ruby using unparser.

The following class of cobol_parser is ported from the open-cobol-1.1 source code.

License

All programs except those in lib/monkey_patches are distributed under the GNU General Public License. See COPYING for details.

lib/monkey_patches/001_lex_more_like_flex.rb is distributed under the MIT License. See piotrmurach/lex - LICENSE.txt for details.

Installation

Add this line to your application's Gemfile:

gem 'cobol_parser'

And then execute:

$ bundle install

Or install it yourself as:

$ gem install cobol_parser

Usage

TODO: Write usage instructions here

Development

After checking out the repo, run bin/setup to install dependencies. Then, run rake test to run the tests. You can also run bin/console for an interactive prompt that will allow you to experiment.

To install this gem onto your local machine, run bundle exec rake install. To release a new version, update the version number in version.rb, and then run bundle exec rake release, which will create a git tag for the version, push git commits and the created tag, and push the .gem file to rubygems.org.

Contributing

Bug reports and pull requests are welcome on GitHub at https://github.com/takaokouji/cobol_parser.