Crates.io | pretty-hash |
lib.rs | pretty-hash |
version | 0.4.1 |
source | src |
created_at | 2018-04-04 00:43:41.933047 |
updated_at | 2020-01-14 17:20:35.304907 |
description | Output binary buffers as a nice, shortened hex string. |
homepage | |
repository | https://github.com/datrs/pretty-hash |
max_upload_size | |
id | 58869 |
size | 29,442 |
Output binary buffers as a nice, shortened hex string. Adapted from pfrazee/pretty-hash.
extern crate pretty_hash;
let hash = pretty_hash::fmt(b"1234").unwrap();
assert_eq!(hash, "31323334");
let hash = pretty_hash::fmt(b"12345").unwrap();
assert_eq!(hash, "313233..35");
$ cargo add pretty-hash
MIT OR Apache-2.0