From: <bms...@us...> - 2006-05-19 21:25:27
|
Revision: 2238 Author: bmsleight Date: 2006-05-19 14:25:19 -0700 (Fri, 19 May 2006) ViewCVS: http://svn.sourceforge.net/morphix/?rev=2238&view=rev Log Message: ----------- Adding my local_build script, builds minis or mains Modified Paths: -------------- trunk/mmaker/utils/auto-testing/AutoTestingMini.xml Added Paths: ----------- trunk/mmaker/utils/local_autobuilds.sh Modified: trunk/mmaker/utils/auto-testing/AutoTestingMini.xml =================================================================== --- trunk/mmaker/utils/auto-testing/AutoTestingMini.xml 2006-05-18 21:51:24 UTC (rev 2237) +++ trunk/mmaker/utils/auto-testing/AutoTestingMini.xml 2006-05-19 21:25:19 UTC (rev 2238) @@ -18,6 +18,7 @@ <X> <!-- Commands to run in X windows --> <command>xscreensaver-command -exit & </command> <command>/bin/bash $1/morphix/files/cat_file.sh</command> + <command>xscreensaver-command -exit & </command> </X> <postX> <!-- Commands to run after X windows shutdown --> <command>echo " * Running AutoTesting debug infomation"</command> Added: trunk/mmaker/utils/local_autobuilds.sh =================================================================== --- trunk/mmaker/utils/local_autobuilds.sh (rev 0) +++ trunk/mmaker/utils/local_autobuilds.sh 2006-05-19 21:25:19 UTC (rev 2238) @@ -0,0 +1,60 @@ +#!/bin/sh +# Copyright (c) 2004, Brendan M. Sleight <bmsleight@barwap._REMOVE_SPAM_TRAP.com> +# +# GPL V2 or later +# +#local_build mini upload_file_dir local_file_dir template_dir +MODULE_TYPE="$1" +TEMPLATE_DIR="$2" +LOCAL_DIR="$3" +UPLOAD_DIR="$4" + +if [ -z "$MODULE_TYPE" -o -z "$TEMPLATE_DIR" -o -z "$LOCAL_DIR" -o -z "$UPLOAD_DIR" ]; then + echo "Usage: $0 mini template_dir local_file_dir upload_file_dir " + echo " " + exit +fi + + +#MAINMODS="/home/morph/local_autobuilds/templates/main/* $1" +#MINIMODS="/home/morph/local_autobuilds/templates/mini/* $2" +#WORKING_DIR="/home/morph/local_autobuilds/builds" +LOCAL_TESTING="/home/morph/autobuilds/" + +upload_scp() { + scp $2/$1.log mo...@lo...:morphixorg/autobuilds/$3/ + scp $2/$1.mod.md5 mo...@lo...:morphixorg/autobuilds/$3/ + scp $2/$1.mod mo...@lo...:morphixorg/autobuilds/$3/ + scp $2/$1.xml mo...@lo...:morphixorg/autobuilds/$3/ + cp $2/$1.log $2/$1.xml $2/$1.mod.md5 $2/$1.mod $LOCAL_TESTING/$3/ +} + +build_main() { +for mod in $TEMPLATE_DIR/*.xml; do + BUILDTIME=`date +"-%F_%H%M"` + BASENAME=`basename ${mod} .xml` + echo "Building $BASENAME" + echo "Start Build: $BUILDTIME" > $LOCAL_DIR/$BASENAME$BUILDTIME.log + if [ "$MODULE_TYPE" = "main" ]; then + sudo mmaker $mod $LOCAL_DIR/$BASENAME$BUILDTIME.mod >> $LOCAL_DIR/$BASENAME$BUILDTIME.log 2>&1 + else + sudo morphmini $mod $LOCAL_DIR/$BASENAME$BUILDTIME.mod >> $LOCAL_DIR/$BASENAME$BUILDTIME.log 2>&1 + fi + md5sum $LOCAL_DIR/$BASENAME$BUILDTIME.mod > $LOCAL_DIR/$BASENAME$BUILDTIME.mod.md5 + ENDTIME=`date +"-%F_%H%M"` + echo "End Build: $ENDTIME" >> $LOCAL_DIR/$BASENAME$BUILDTIME.log + cp $mod $LOCAL_DIR/$BASENAME$BUILDTIME.xml + upload_scp "$BASENAME$BUILDTIME" "$LOCAL_DIR" "$UPLOAD_DIR" >> $LOCAL_DIR/$BASENAME$BUILDTIME.log + # Cleanup time! + sudo rm -rf /tmp/libmorphix* +done +} + + +build_main + +# delete all files in WORKING_DIR after 3 days +find $LOCAL_DIR/[^local]* -ctime +1 -exec rm {} \; + + + Property changes on: trunk/mmaker/utils/local_autobuilds.sh ___________________________________________________________________ Name: svn:executable + * This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <bms...@us...> - 2006-10-28 21:21:29
|
Revision: 2436 http://svn.sourceforge.net/morphix/?rev=2436&view=rev Author: bmsleight Date: 2006-10-28 14:21:19 -0700 (Sat, 28 Oct 2006) Log Message: ----------- Updating some of the autotesting scripts. These really could do with a good rewrite, but if it is not broken ... .. . Modified Paths: -------------- trunk/mmaker/utils/auto-testing/auto_testing.sh trunk/mmaker/utils/auto-testing/run_testing.sh trunk/mmaker/utils/local_autobuilds.sh Modified: trunk/mmaker/utils/auto-testing/auto_testing.sh =================================================================== --- trunk/mmaker/utils/auto-testing/auto_testing.sh 2006-10-26 19:53:40 UTC (rev 2435) +++ trunk/mmaker/utils/auto-testing/auto_testing.sh 2006-10-28 21:21:19 UTC (rev 2436) @@ -36,6 +36,7 @@ DUMPS=$TMP_D/dump mkdir $TMP_D 2>/dev/null +LIST_ISOMORPH=$(echo ; isomorph --list $ISO ) isomorph --add boot "splash=n debugmorphix=yes" $ISO $TMP_D/qemu.iso qemu -full-screen -pidfile $TMP_D/qemu.pid -user-net -cdrom $TMP_D/qemu.iso & @@ -84,8 +85,9 @@ # Create the intro to the video title="Autotesting using Qemu" -text=" $ISO \n \n The iso has been ammended to help debugging \n Added the bootoptions splash=n debugmorphix=y \n Also added a mini-module Morphix-Mini-Debug-Auto-Testing.mod \n This mini-module prints out debug information to the screen \n of course the iso does not normally contain this minimodule \n or display this information. \n \n $COMMENTS" -convert -size 600x440 xc:white -pointsize 25 -fill darkblue -annotate 0x0+250+75 "$title" -pointsize 16 -fill blue -annotate 0x0+50+200 "$text" -append $LOGO -bordercolor darkblue -border 20x20 -flatten "$DUMPS"0.jpg +text=" $ISO - The iso has been ammended to help debugging. The boot-options splash=n debugmorphix=y have been added and a MiniModule Morphix-Mini-Debug-Auto-Testing.mod added. This MiniModule prints out debug information to the screen, the iso does not normally contain this MiniModule or display this information. \n $LIST_ISOMORPH \n \n $COMMENTS" +FOLD_TEXT==$(echo "$text" | fold -s -w 100 ) +convert -size 600x440 xc:white -pointsize 25 -fill darkblue -annotate 0x0+250+75 "$title" -pointsize 10 -fill blue -annotate 0x0+50+200 "$FOLD_TEXT" -append $LOGO -bordercolor darkblue -border 20x20 -flatten "$DUMPS"0.jpg convert "$DUMPS"0.jpg -resize 800x600 "$DUMPS"1.jpg mv "$DUMPS"1.jpg "$DUMPS"0.jpg l=1 Modified: trunk/mmaker/utils/auto-testing/run_testing.sh =================================================================== --- trunk/mmaker/utils/auto-testing/run_testing.sh 2006-10-26 19:53:40 UTC (rev 2435) +++ trunk/mmaker/utils/auto-testing/run_testing.sh 2006-10-28 21:21:19 UTC (rev 2436) @@ -23,6 +23,7 @@ DEBUG_MINI=/home/morph/minimods/Morphix-Mini-Debug-Auto-Testing.mod TMP_ISO_DIR=/tmp/iso +TMP_TAR_DIR=/tmp/iso/tar/ TMP_ISO_1=$TMP_ISO_DIR/tmp1.iso TMP_ISO_2=$TMP_ISO_DIR/tmp2.iso TMP_ISO_3=$TMP_ISO_DIR/start.iso @@ -32,8 +33,11 @@ DIVIDER="######################################################" TITLED="------------------------------------------------------- " + + mkdir $TMP_ISO_DIR 2>/dev/null mkdir $VID_DIR 2>/dev/null +mkdir $TMP_TAR_DIR 2>/dev/null export DISPLAY=:0.0 @@ -145,6 +149,9 @@ date cp $TMP_BASES $TMP_ISO_1 for EACH_MINI in $ALL_MINIS; do + echo $DIVIDER + echo "Adding " $EACH_MINI + echo $DIVIDER sudo isomorph --add mini $EACH_MINI $TMP_ISO_1 $TMP_ISO_3 mv $TMP_ISO_3 $TMP_ISO_1 done @@ -154,6 +161,9 @@ echo "Run auto_testing" echo $TITLED date + echo $DIVIDER + sudo isomorph --list $TMP_ISO_DIR/$TMP_MAINMODS_BN'_'$TMP_BASES_BN + echo $DIVIDER sudo /home/morph/morphix/trunk/mmaker/utils/auto-testing/auto_testing.sh $TMP_ISO_DIR/$TMP_MAINMODS_BN'_'$TMP_BASES_BN $VID_DIR/$TMP_MAINMODS_BN'_'$TMP_BASES_BN.avi 700 sudo rm $TMP_ISO_DIR/$TMP_MAINMODS_BN'_'$TMP_BASES_BN echo $TMP_ISO_DIR/$TMP_MAINMODS_BN'_'$TMP_BASES_BN @@ -164,12 +174,33 @@ date rsync -avz --delete -e ssh $VID_DIR mo...@lo...:morphixorg/autobuilds/video/ cp $VID_DIR/$TMP_MAINMODS_BN'_'$TMP_BASES_BN.ogg /home/morph/autobuilds/video/ + date # This machine get hot - have 20 minutes to cool down - date sleep 1200 date fi + #Zip the log and xml files of the base and main_modules + TMP_BASES_DIRNAME=$(cd $(dirname "${TMP_BASES}") && pwd) + TMP_BASES_BN_NO_EXT=${TMP_BASES_BN%.*} + cp $TMP_BASES_DIRNAME/$TMP_BASES_BN_NO_EXT.log $TMP_BASES_DIRNAME/$TMP_BASES_BN_NO_EXT.xml $TMP_TAR_DIR/ done + TMP_MAINMODS_DIRNAME=$(cd $(dirname "${TMP_MAINMODS}") && pwd) + TMP_MAINMODS_NO_EXT=${TMP_MAINMODS_BN%.*} + cp $TMP_MAINMODS_DIRNAME/$TMP_MAINMODS_NO_EXT.log $TMP_MAINMODS_DIRNAME/$TMP_MAINMODS_NO_EXT.xml $TMP_TAR_DIR/ done - +for EACH_MINI in $ALL_MINIS; do + TMP_EACH_MINI_BN=$(basename $EACH_MINI) + TMP_EACH_MINI_NO_EXT=${TMP_EACH_MINI_BN%.*} + TMP_EACH_MINI_DIRNAME=$(cd $(dirname "${EACH_MINI}") && pwd) + cp $TMP_EACH_MINI_DIRNAME/$TMP_EACH_MINI_NO_EXT.xml $TMP_EACH_MINI_DIRNAME/$TMP_EACH_MINI_NO_EXT.log $TMP_TAR_DIR/ +done +echo "List tmp tar dir" +ls $TMP_TAR_DIR/ -lrth +cd $TMP_TAR_DIR ; tar cvzf $VID_DIR/$TODAY.log_xml.tar.gz $TMP_TAR_DIR/* +echo $DIVIDER +echo "Upload log and xml as tar.gz" +echo $TITLED +gzip -c $LOG_FILE >$VID_DIR/$LOG_FILE_BN'_'$TODAY'_.gz' +rsync -avz --delete -e ssh $VID_DIR mo...@lo...:morphixorg/autobuilds/video/ +rm $TMP_TAR_DIR/* sudo rm $TMP_ISO_DIR -r Modified: trunk/mmaker/utils/local_autobuilds.sh =================================================================== --- trunk/mmaker/utils/local_autobuilds.sh 2006-10-26 19:53:40 UTC (rev 2435) +++ trunk/mmaker/utils/local_autobuilds.sh 2006-10-28 21:21:19 UTC (rev 2436) @@ -36,6 +36,7 @@ echo "Building $BASENAME" echo "Start Build: $BUILDTIME" > $LOCAL_DIR/$BASENAME$BUILDTIME.log if [ "$MODULE_TYPE" = "main" ]; then + echo $mod $LOCAL_DIR/$BASENAME$BUILDTIME.mod sudo mmaker $mod $LOCAL_DIR/$BASENAME$BUILDTIME.mod >> $LOCAL_DIR/$BASENAME$BUILDTIME.log 2>&1 else sudo morphmini $mod $LOCAL_DIR/$BASENAME$BUILDTIME.mod >> $LOCAL_DIR/$BASENAME$BUILDTIME.log 2>&1 @@ -54,7 +55,7 @@ build_main # delete all files in WORKING_DIR after 3 days -find $LOCAL_DIR/[^local]* -ctime +1 -exec rm {} \; +find $LOCAL_DIR/[^local]* -ctime +1 -exec sudo rm {} \; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <pa...@us...> - 2007-05-24 11:37:47
|
Revision: 2495 http://svn.sourceforge.net/morphix/?rev=2495&view=rev Author: paul_c Date: 2007-05-24 04:37:38 -0700 (Thu, 24 May 2007) Log Message: ----------- A couple of tweaks to the autobuild scripts. Modified Paths: -------------- trunk/mmaker/utils/build-example.sh trunk/mmaker/utils/local_autobuilds.sh Modified: trunk/mmaker/utils/build-example.sh =================================================================== --- trunk/mmaker/utils/build-example.sh 2007-05-24 10:47:06 UTC (rev 2494) +++ trunk/mmaker/utils/build-example.sh 2007-05-24 11:37:38 UTC (rev 2495) @@ -38,7 +38,7 @@ done # delete all files in alextreme after 3 days -find alextreme/*.* -ctime +3 -prune -exec rm {} \; +find alextreme/*.* -maxdepth 0 -mtime +3 -exec rm -f {} \; # Cleanup time! rm -rf /tmp/libmorphix* Modified: trunk/mmaker/utils/local_autobuilds.sh =================================================================== --- trunk/mmaker/utils/local_autobuilds.sh 2007-05-24 10:47:06 UTC (rev 2494) +++ trunk/mmaker/utils/local_autobuilds.sh 2007-05-24 11:37:38 UTC (rev 2495) @@ -54,5 +54,5 @@ build_main # delete all files in WORKING_DIR after 3 days -find $LOCAL_DIR/[^local]* -ctime +1 -exec sudo rm {} \; +find $LOCAL_DIR/* -maxdepth 0 -mtime +1 -exec sudo rm -f {} \; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |