On Fri, Dec 19, 2014 at 12:02 PM, Rob Landley <r...@landley.net> wrote:
> On 12/19/2014 12:40 AM, enh wrote:
>> (note that all lists were generated by hand so might not be exactly
>> right, but should give the rough idea.)
>
> This is entire message is awesome and I'll probably devote the whole
> weekend to follow-up, but lemme reply to one specific part now:
>
>>    df --- our non-standard output is parsed by tradefed.
>
> In response to the earlier human readable thread I've torn apart my
> local copy and am rewriting it to do the "readahead and measure the
> column spacing" trick (since adding -h spacing as a third special case
> got kind of silly).
>
> It looks like your output is 5 columns (Filesystem, Size, Used, Free,
> Blksize), columns 2-4 are -h format, and the first column is mount point
> rather than block device.
>
> I can do all that, but:
>
> 1) Can I add a new command line option to produce this output? Maybe
> dash capital A? (Trying to resolve conflicting expectations for users in
> different contexts...)

i'd actually bump df down your priority list. i was certainly planning
on coming back to it last. i want to talk to the testing team about
exactly this, and whether they need to talk to old and new devices.

> 2) Does the stuff parsing it care about the spacing, or will the
> auto-spacing (varying based on the readings) work for them?

looks like they use this regular expression right now:

                "%s\\s+[\\w\\d\\.]+\\s+[\\w\\d\\.]+\\s+([\\d\\.]+)(\\w)"

one thing that's interesting is that they already have code that says
"Parses a partitions available space from the legacy output of a 'df'
command.". i'll get in touch with them, but things are already winding
down here so it might be 2015 before i can get a canonical answer.

 --elliott
_______________________________________________
Toybox mailing list
Toybox@lists.landley.net
http://lists.landley.net/listinfo.cgi/toybox-landley.net

Reply via email to