Skip to content
Snippets Groups Projects
Select Git revision
  • 007fdfd0f7116d481e54505f3085edc7c0d3cc9a
  • master default
  • trunk
  • RELEASE_6_5_DRIVEDB
  • RELEASE_6_6_DRIVEDB
  • RELEASE_7_0_DRIVEDB
  • RELEASE_7_2_DRIVEDB
  • RELEASE_7_3_DRIVEDB
  • RELEASE_6_0_DRIVEDB
  • RELEASE_6_1_DRIVEDB
  • RELEASE_6_2_DRIVEDB
  • RELEASE_6_3_DRIVEDB
  • RELEASE_6_4_DRIVEDB
  • tags/RELEASE_7_4
  • tags/RELEASE_7_3
  • RELEASE_5_41_DRIVEDB
  • RELEASE_5_42_DRIVEDB
  • RELEASE_5_43_DRIVEDB
  • tags/RELEASE_7_2
  • tags/RELEASE_7_1
  • tags/RELEASE_7_0
  • RELEASE_5_40_DRIVEDB
22 results

smartd.cpp

Blame
  • script 575 B
    #! /bin/bash
    
    # This is a script to wrap smartctl output into http:// displayable form
    # It requires a filename as input, and produces an file with a .html extension as output
    
    if [ $# -ne 1 ] ; then
    	echo This script requires one a file as input
    	exit 1
    fi
    
    model=`grep "Device Model"  $1  | awk '{print $3}' `
    
    # see if file name in use
    let i=0
    while [ -f $model-$i.html ] ; do
    	let i+=1
    done
    
    filename=$model-$i
    echo -e "<pre><tt>\n"    > $filename.html
    cat $1                  >> $filename.html
    echo -e "</tt></pre>\n" >> $filename.html
    
    echo created file $filename.html