len

Crates.iolen
lib.rslen
version0.2.0
sourcesrc
created_at2019-11-03 10:16:22.830611
updated_at2021-12-16 23:43:35.387714
descriptionCommand to print length of stdin in a human-friendly format
homepagehttps://github.com/robertknight/len
repositoryhttps://github.com/robertknight/len.git
max_upload_size
id177723
size4,092
Robert Knight (robertknight)

documentation

README

len

Command that reads stdin and prints its length in bytes, with human-friendly formatting if the output is a terminal.

Installation

Install Cargo, the package manager for the Rust programming language. Then run:

$ cargo install len

Usage

$ cat /usr/share/dict/words | len

2.4 MiB

len will print its output in human-readable format if the output is a terminal, or a plain number otherwise, in which case it is the same as using wc -c.

Commit count: 5

cargo fmt