On Fri, 30 Jan 2004 22:55:33 +0000
Paul Stear <[EMAIL PROTECTED]> wrote:

> On Fri 30 January 2004 18:51, Andrej Kacian wrote:
> > On Fri, 30 Jan 2004 19:27:51 +0100
> >
> > Norbert Kamenicky <[EMAIL PROTECTED]> wrote:
> > > Paul Stear wrote:
> > > > I can get the disc size so all I need is to calculate the used size and
> > > > then subtract.
> > > > Or is there an easier way?
> <snip>
> > Paul, you need the "df" utility.
> 
> Thanks to all who replied, I just need to right justify the figures in the 
> output of the script????

What do you mean by that?

If you need to get a particular figure from the output, you can use awk, f.e.:

FREE=`df | grep /home$ | awk '{print $4}'`

to get amount of available space in bytes (4th column of output) for partition
mounted on/home.

-- 
/~\ The ASCII        Andrej "Ticho" Kacian <andrej at kacian dot sk>
\ / Ribbon Campaign  GnuPG public key ID: 7CD93FE2 (pgp.mit.edu)
 X  Against HTML     Key fingerprint:
/ \ Email!           E87D 9DEF 2A23 6FFB 7AD9 542F 4253 3A46 7CD9 3FE2

Attachment: pgp00000.pgp
Description: PGP signature

Reply via email to