coreutils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Command-line program to convert 'human' sizes?


From: Pádraig Brady
Subject: Re: Command-line program to convert 'human' sizes?
Date: Tue, 04 Dec 2012 23:11:54 +0000
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:13.0) Gecko/20120615 Thunderbird/13.0.1

On 12/04/2012 10:55 PM, Assaf Gordon wrote:
Hello,

Pádraig Brady wrote, On 12/04/2012 11:30 AM:
Nothing yet. The plan is to make a numfmt command available with this interface:
http://lists.gnu.org/archive/html/coreutils/2012-02/msg00085.html


Attached is a patch, with a proof-of-concept working 'numfmt'.

Works: from=SI/IEC/AUTO, to=SI/IEC, from-units, to-units, suffix, round.
Doesn't work: format, to=<NUMBER>,field=N .

The code isn't clean and can be improved.
Currently, either  every (non-option) command-line parameter is expected to be 
a number, or every line on stdin is expected to start with a number.

Thanks a lot for working on this.
All I'll say at this stage is to take it
as far as you can as per the interface specified
at the above URL with a mind to reusing stuff from
lib/human.c if possible.

We'll review it then with a view to including it ASAP.

thanks,
Pádraig.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]