Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/polsab/pretty_hex
A binary hex dumping library in Elixir.
https://github.com/polsab/pretty_hex
Last synced: 3 months ago
JSON representation
A binary hex dumping library in Elixir.
- Host: GitHub
- URL: https://github.com/polsab/pretty_hex
- Owner: polsab
- Created: 2014-11-06T19:02:43.000Z (about 10 years ago)
- Default Branch: master
- Last Pushed: 2024-05-17T17:55:48.000Z (8 months ago)
- Last Synced: 2024-10-09T05:43:33.530Z (4 months ago)
- Language: Elixir
- Size: 133 KB
- Stars: 7
- Watchers: 2
- Forks: 1
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
- freaking_awesome_elixir - Elixir - A binary hex dumping library in Elixir. (Text and Numbers)
- fucking-awesome-elixir - pretty_hex - A binary hex dumping library in Elixir. (Text and Numbers)
- awesome-elixir - pretty_hex - A binary hex dumping library in Elixir. (Text and Numbers)
README
PrettyHex
=========PrettyHex is an Elixir library for hex dumping of binaries/strings.
## Example
```elixir
iex> PrettyHex.pretty_hex("This is a test. Just a test.")
00000000: 54 68 69 73 20 69 73 20 61 20 74 65 73 74 2E 20 This.is.a.test..
00000010: 4A 75 73 74 20 61 20 74 65 73 74 2E Just.a.test.iex> PrettyHex.pretty_hex("Another test.", 0x10f0)
000010F0: 41 6E 6F 74 68 65 72 20 74 65 73 74 2E Another.test.iex> PrettyHex.pretty_hex(<<0x45, 0x55, 0xff, 0x12, 0x32, 0x16, 0x70>>, 0xfc00, 64)
000000000000FC00: 45 55 FF 12 32 16 70 EU..2.p
```