#!/bin/ksh
#
#####
#####  Written by Paul A. Luzzi on 02-01-2002
#####
#####    version 1 written 02-01-2002
#####    version 1.1 updated 07-12-2002 to handle proper sorting
#####    version 1.2 updated 08-21-2002 to handle proper spacing
#####
#####  Script name : $BBHOME/ext/hpux_df.sh
#####
#####  Small extension script written for HP-UX to allow the 
#####    the df output to all come out on one line per filesystem
#####    instead of the HP specific "two line" for long f/s names.
#####
#####  Uses bbsys.local's new variable called DFPROPER, and the
#####    bbsys.sh file MUST have its DF entry commented out.
#####    Example lines from configured bbsys.local are as follows :
#####
#####      DFPROPER="/usr/bin/df " 
#####      DF="$BBHOME/ext/hpux_df.sh"
#####      export DFPROPER DF
#####
for device in ` $DFPROPER -Pl | $GREP -v Filesystem | $AWK '$1 ~ /\// {print $1}'` 
 do
   print "$device \t \c"
   $DFPROPER -Pl $device | $TAIL -1 | $AWK ' $1 ~ /^[0-9].[0-9]/ {print $1,"\t",$2,"\t",$3,"\t",$4,"\t",$5} $1 ~ /\// {print "\t"$2,"\t",$3,"\t",$4,"\t",$5,"\t",$6}'
 done | $SORT -n -k $DFSORT

#####
#####  End of hpux_df.sh
#####
