[Top][All Lists]

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

Re: feature request: make df as pretty as ls -l

From: Peter D.
Subject: Re: feature request: make df as pretty as ls -l
Date: Mon, 26 Feb 2007 22:51:41 +1100
User-agent: KMail/1.9.4

On Monday 26 February 2007 21:12, Pádraig Brady wrote:
> Peter D. wrote:
> > Hi,
> >
> > I have a feature request.  Can the output from "df" be columnated, like
> > the output from "ls -l"?
> >
> > Having thousands separators is great.  It makes the output from "df ."
> > much more human friendly (I have "export BLOCK_SIZE=\'1" in my
> > ~/.bashrc) but the ouput of "df" below is not as legible as I would
> > like.
> columnated output is on the TODO list.
> It's worth noting also that `df -h` has nicely columnated
> output with enough resolution for most uses.
> Also note the separate (non coreutil) `column` util.
> This will get the alignment wrong, but it might be of some use?
> BLOCK_SIZE=\'1 df | column -t
> Pádraig.

You are right, it works better than I thought.  It is fine up to 9 
characters, either 9 digits or 7 digits and 2 commas.  Piping 
through "column -t" is good, but numbers end up being left aligned instead 
of right aligned.  Is it worth sending a feature request to the column 
people?  Who are they?  

Since "df" almost always deals with multi MegaByte values my best immediate 
response is to add "DF_BLOCK_SIZE=\'M" to my bashrc.  It will consume 
another character for the "M" and a second one for the impossible leading 
comma.  That would give a maximum pretty output of "999,999M", more than 
enough for my current hardware.  

Thank you.  

sig goes here...
Peter D.

reply via email to

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