From 2ce62299835b7d9d972d6758373aae54540a3c7c Mon Sep 17 00:00:00 2001 From: Holger Levsen Date: Sun, 2 Nov 2014 15:27:23 +0100 Subject: g-i-i: provide screenshot+thumb in workspace for the live-screenshot plugin --- bin/g-i-installation.sh | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/bin/g-i-installation.sh b/bin/g-i-installation.sh index ae3d4230..cfd72291 100644 --- a/bin/g-i-installation.sh +++ b/bin/g-i-installation.sh @@ -934,15 +934,17 @@ monitor_system() { echo "$(date) $PRINTF_NR - could not take vncsnapshot from $DISPLAY - using a blank fake one instead" convert -size $VIDEOSIZE xc:none -depth 8 snapshot_${PRINTF_NR}.png fi - # give signal we are still running - if [ $(($NR % 14)) -eq 0 ] ; then - echo "$(date) $PRINTF_NR / $TOKEN" - fi + # every 100 ticks take a screenshot and preserve and analyse it if [ $(($NR % 100)) -eq 0 ] ; then # press ctrl-key regularily to avoid screensaver kicking in vncdo -s $DISPLAY key ctrl || true # preserve a screenshot for later publishing backup_screenshot + # make screenshots available for the live screenshot plugin + ln -f $PWD/snapshot_${PRINTF_NR}.png $WORKSPACE/screenshot.png + convert $WORKSPACE/screenshot.png -adaptive-resize 128x96 $WORKSPACE/screenshot-thumb.png.new + rm -f $WORKSPACE/screenshot-thumb.png + mv $WORKSPACE/screenshot-thumb.png.new $WORKSPACE/screenshot-thumb.png # # search for known text using ocr of screenshot and break out of this loop if certain content is found # @@ -983,6 +985,9 @@ monitor_system() { echo "ERROR: The failing step is: Build LTSP chroot." >> $GOCR exit 1 fi + elif [ $(($NR % 30)) -eq 0 ] ; then + # give signal we are still running + echo "$(date) $PRINTF_NR / $TOKEN" fi # every 100 screenshots, starting from the $TIMEOUTth one... if [ $(($NR % 100)) -eq 0 ] && [ $NR -gt $TIMEOUT ] ; then -- cgit v1.2.3-54-g00ecf