hrx

Parser for the Human Readable Archive (HRX) format

hrx

This shard provides a parser for the Human Readable Archive (HRX) format.

Installation

  1. Add the dependency to your shard.yml:

    dependencies:
      hrx:
        github: straight-shoota/hrx
    
  2. Run shards install

Usage

require "hrx"

File.write("archive.hrx", "<==> foo.txt\nFOO\n<==> bar.txt\nBAR")
archive = File.open("archive.hrx", "r") do |io|
  HRX.parse(io)
end
archive["foo.txt"] # => HRX::File.new("foo.txt", "FOO", nil, 1, 6)
archive["bar.txt"] # => HRX::File.new("bar.txt", "BAR", nil, 3, 6)

Contributing

  1. Fork it (https://github.com/straight-shoota/hrx/fork)
  2. Create your feature branch (git checkout -b my-new-feature)
  3. Commit your changes (git commit -am 'Add some feature')
  4. Push to the branch (git push origin my-new-feature)
  5. Create a new Pull Request

Contributors

Repository

hrx

Owner
Statistic
  • 1
  • 0
  • 0
  • 2
  • 0
  • over 3 years ago
  • May 12, 2020
License

Apache License 2.0

Links
Synced at

Sat, 18 May 2024 06:13:03 GMT

Languages