Pádraig Brady wrote:
...
> Looking more at this, you might be right.
> Now printf already has related formatting functionality:
>
> $ env LANG=fa_IR.utf8 printf "%I'd\n" 1234
> ۱٬۲۳۴
>
> I was thinking it would be appropriate to add "human" into the mix like
>
> $ env LANG=fa_IR.utf8 printf "%Hd\n" 1234
> 1K
>
> $ env LANG=fa_IR.utf8 printf "%HId\n" 1234
> ۱K
>
> But as you say there are options for humanizing.
> So would there be enough cohesive functionality one could add to such a util?
> I suppose so, since one could add field processing and
> multiplier support for example.
>
> Also what to call it? humanize_number is too long I think.
> Perhaps we could use a more general name. Drats I was
> thinking of `numconv`, but that's taken:
> http://www.unixref.com/manPages/numconv.html
> Maybe `convnum`, anyway...

human-readable   too long and hyphenated
hr               short, but in the unix tradition (like od, dd, etc.)

> A tentative design could be:
>
> convnum [OPTIONS] [NUM]...
>
> Numbers are processed from stdin or the command options.

Perhaps this, instead:

  Convert numbers to human readable form.

Reply via email to