validation script fixed (some sed expressions)
This commit is contained in:
parent
2521d5f74a
commit
2780ec34b6
|
@ -29,6 +29,7 @@ function do_single()
|
||||||
cp "$1/description" "${2}/${TESTNAME}.desc"
|
cp "$1/description" "${2}/${TESTNAME}.desc"
|
||||||
# sleep, if a file called 'delay' exists
|
# sleep, if a file called 'delay' exists
|
||||||
[ -e "$1/delay" ] && sleep "$(<$1/delay)"
|
[ -e "$1/delay" ] && sleep "$(<$1/delay)"
|
||||||
|
true
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -80,13 +81,13 @@ function import_style()
|
||||||
[ -e "$VALIDATE_REPORT_DIR/cryptobox.css" ] && rm "$VALIDATE_REPORT_DIR/cryptobox.css"
|
[ -e "$VALIDATE_REPORT_DIR/cryptobox.css" ] && rm "$VALIDATE_REPORT_DIR/cryptobox.css"
|
||||||
wget -q -O "$VALIDATE_REPORT_DIR/cryptobox.css" http://$VALIDATE_HOST_IP_DEFAULT/cryptobox.css
|
wget -q -O "$VALIDATE_REPORT_DIR/cryptobox.css" http://$VALIDATE_HOST_IP_DEFAULT/cryptobox.css
|
||||||
# extract image file names
|
# extract image file names
|
||||||
grep "url(/cryptobox-img/" "$VALIDATE_REPORT_DIR/cryptobox.css" | sed 's#^.*url(/cryptobox-img/\(.*\)).*$#\1#' | while read a
|
grep "url(cryptobox-img/" "$VALIDATE_REPORT_DIR/cryptobox.css" | sed 's#^.*url(cryptobox-img/\(.*\)).*$#\1#' | while read a
|
||||||
do wget -q -O "$VALIDATE_REPORT_DIR/cryptobox-img/$a" "http://$VALIDATE_HOST_IP_DEFAULT/cryptobox-img/$a"
|
do wget -q -O "$VALIDATE_REPORT_DIR/cryptobox-img/$a" "http://$VALIDATE_HOST_IP_DEFAULT/cryptobox-img/$a"
|
||||||
done
|
done
|
||||||
|
|
||||||
# change the stylesheet link in every html file in REPORT_DIR
|
# change the stylesheet link in every html file in REPORT_DIR
|
||||||
find "$VALIDATE_REPORT_DIR" -type f -name \*.html | while read a
|
find "$VALIDATE_REPORT_DIR" -type f -name \*.html | while read a
|
||||||
do sed -i '#link rel="stylesheet"#s#href="/cryptobox.css"#href="../cryptobox.css"#g' "$a"
|
do sed -i '/stylesheet/s#href=\"/cryptobox.css\"#href=\"../cryptobox.css\"#g' "$a"
|
||||||
done
|
done
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue