|
|
|
@ -107,13 +107,13 @@ import_style()
|
|
|
|
|
# get the stylesheet file and images
|
|
|
|
|
# change the stylesheet link
|
|
|
|
|
{
|
|
|
|
|
[ -d "VALIDATE_REPORT_DIR/img" ] && rm -r "$VALIDATE_REPORT_DIR/img"
|
|
|
|
|
mkdir -p "$VALIDATE_REPORT_DIR/img"
|
|
|
|
|
[ -d "$VALIDATE_REPORT_DIR/cryptobox-img" ] && rm -r "$VALIDATE_REPORT_DIR/cryptobox-img"
|
|
|
|
|
mkdir -p "$VALIDATE_REPORT_DIR/cryptobox-img"
|
|
|
|
|
[ -e "$VALIDATE_REPORT_DIR/cryptobox.css" ] && rm "$VALIDATE_REPORT_DIR/cryptobox.css"
|
|
|
|
|
wget -q -O "$VALIDATE_REPORT_DIR/cryptobox.css" http://$VALIDATE_HOST_IP:$VALIDATE_HTTP_PORT/cryptobox.css
|
|
|
|
|
# extract image file names
|
|
|
|
|
grep "url(img/" "$VALIDATE_REPORT_DIR/cryptobox.css" | sed 's#^.*url(img/\(.*\)).*$#\1#' | while read a
|
|
|
|
|
do wget -q -O "$VALIDATE_REPORT_DIR/img/$a" "http://$VALIDATE_HOST_IP:$VALIDATE_HTTP_PORT/img/$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:$VALIDATE_HTTP_PORT/cryptobox-img/$a"
|
|
|
|
|
done
|
|
|
|
|
|
|
|
|
|
# change the stylesheet link in every html file in REPORT_DIR
|
|
|
|
|