hexa.cr/README.md

745 B

hexa

Bindings to libhexa to produce hexadecimal dumps of arbitrary input bytes. This prints debug info in a pretty way.

Installation

  1. Add the dependency to your shard.yml:

    dependencies:
      hexa:
        branch: master
        git: https://git.baguette.netlib.re/Baguette/hexa.cr.git
    
  2. Run shards install

Usage

require "hexa"

h = Hexa.new 5_000 # Size of the output buffer.

# First, an hexadecimal dump of a small text.
text = "hello this is some text" # could be Bytes
puts h.dump text

# With a centered title on the first line.
title = "itz mai title lul"
puts h.dump title, text

Contributors