"Fossies" - the Fresh Open Source Software Archive

Member "systeminfo/report/disk.sh" (4 Feb 2005, 377 Bytes) of package /linux/privat/old/systeminfov12.tar.gz:


As a special service "Fossies" has tried to format the requested source page into HTML format using (guessed) Bash source code syntax highlighting (style: standard) with prefixed line numbers. Alternatively you can here view or download the uninterpreted source code file.

    1 #!/bin/sh
    2 # Disk Info Generator
    3 while read line; do
    4 echo $line | grep -q 'span style="font-weight:"'
    5 if [[ $? -eq 0 ]]
    6 then
    7     echo $line;
    8     fdisk -l | while read ln; do
    9     [[ ! -z " " ]] && echo "$ln<br>";
   10     done
   11     echo "<br><b>Disk Free :</b><br><br>"
   12     df -h | while read ln; do
   13     echo "$ln<br>";
   14     done
   15 else
   16     echo $line;
   17 fi
   18 done < disk.html > $1/disk.html