]> git.argeo.org Git - gpl/argeo-slc.git/blobdiff - buildSite.sh
Alpha version of SLC Repo: can serve as backend for building Argeo Commons Basic
[gpl/argeo-slc.git] / buildSite.sh
index 9b8c18c494d3c4c9336f1e15aeb338d1bec4e44a..7992e7448aa6458f687b65cc92633f60adfb0a0b 100755 (executable)
@@ -14,9 +14,12 @@ HOSTNAME=`hostname -f`
 DATE=`date -u`
 EXIT_STATUS=0
 
+export MAVEN_OPTS=-Xmx256m
+export PATH=$PATH:/usr/local/bin
+
 # BUILD
-mvn --fail-at-end deploy $PROFILES 2>&1 | tee deploy.log
-EXIT_STATUS=$?
+/usr/local/bin/mvn -up --fail-at-end deploy $PROFILES 2>&1 | tee deploy.log
+EXIT_STATUS=$PIPESTATUS
 if [ $EXIT_STATUS -eq 0 ]
 then
        mail -s "Build@$HOSTNAME SUCCESS - $DATE - $BUILD_DIR" $TO < pom.xml
@@ -24,13 +27,19 @@ else
        mail -s "Build@$HOSTNAME FAILURE - $DATE - $BUILD_DIR" $TO < deploy.log
 fi
 
+# SDK
+#cd dist/org.argeo.slc.sdk
+#/usr/local/bin/mvn deploy
+#cd ../..
+
 # SITE
-mvn --fail-at-end site-deploy $PROFILES 2>&1 | tee siteGeneration.log
-if [ $? -eq 0 ]
+/usr/local/bin/mvn -up --fail-at-end site-deploy $PROFILES 2>&1 | tee siteGeneration.log
+if [ $PIPESTATUS -eq 0 ]
 then
        echo No need to send email for successful site generation
 else
        mail -s "SiteGeneration@$HOSTNAME FAILURE - $DATE - $BUILD_DIR" $TO < siteGeneration.log
 fi
 
+
 exit $EXIT_STATUS