[Debian-live-changes] r1619 - in dists/trunk/live-webbuilder: . templates
daniel at alioth.debian.org
daniel at alioth.debian.org
Tue May 22 21:20:39 UTC 2007
Author: daniel
Date: 2007-05-22 21:20:39 +0000 (Tue, 22 May 2007)
New Revision: 1619
Added:
dists/trunk/live-webbuilder/templates/mail.txt
Modified:
dists/trunk/live-webbuilder/Makefile
dists/trunk/live-webbuilder/cron
dists/trunk/live-webbuilder/live-webbuilder
dists/trunk/live-webbuilder/templates/header.html
Log:
Modified: dists/trunk/live-webbuilder/Makefile
===================================================================
--- dists/trunk/live-webbuilder/Makefile 2007-05-22 21:16:11 UTC (rev 1618)
+++ dists/trunk/live-webbuilder/Makefile 2007-05-22 21:20:39 UTC (rev 1619)
@@ -15,8 +15,8 @@
install -D -m 0755 live-webbuilder $(DESTDIR)/usr/lib/cgi-bin/live-webbuilder
# Installing templates
- mkdir -p $(DESTDIR)/usr/share/live-webbuilder/html
- cp html/*.html $(DESTDIR)/usr/share/live-webbuilder/html
+ mkdir -p $(DESTDIR)/usr/share/live-webbuilder/templates
+ cp templates/*.html templates/*.txt $(DESTDIR)/usr/share/live-webbuilder/templates
# Installing documentation
install -D -m 0755 COPYING $(DESTDIR)/usr/share/doc/live-webbuilder/COPYING
Modified: dists/trunk/live-webbuilder/cron
===================================================================
--- dists/trunk/live-webbuilder/cron 2007-05-22 21:16:11 UTC (rev 1618)
+++ dists/trunk/live-webbuilder/cron 2007-05-22 21:20:39 UTC (rev 1619)
@@ -8,6 +8,8 @@
# This is free software, and you are welcome to redistribute it
# under certain conditions; see COPYING for details.
+TEMPLATES="/usr/share/live-webbuilder/templates"
+
# Reading defaults
if [ -r /etc/default/live-webbuilder ]
then
@@ -41,8 +43,6 @@
then
for FILE in "${TEMPDIR}"/*.build
do
- DATE_START="`date -R`"
-
# Reading build file
. "${FILE}"
@@ -100,8 +100,20 @@
# Creating build directory
mkdir -p "${TEMPDIR}"/"${BUILD}"
+ DATE_START="`date -R`"
+ echo "Begin: ${DATE_START}" > "${TEMPDIR}"/"${BUILD}"/log.txt
+
+ # Generating image
cd "${TEMPDIR}"/"${BUILD}"
+ make-live ${LIVE_OPTIONS} >> "${TEMPDIR}"/"${BUILD}"/log.txt 2>&1
+ ERROR="${?}"
+ DATE_END="`date -R`"
+ echo "End: ${DATE_END}" >> "${TEMPDIR}"/"${BUILD}"/log.txt
+
+ # Creating image directory
+ mkdir -p "${DESTDIR}"/"${BUILD}"
+
# First part of user email.
cat > "${TEMPDIR}"/"${BUILD}"/mail.txt << EOF
Subject: Debian Live Webbuilder - Build ${BUILD}
@@ -118,19 +130,7 @@
EOF
- echo "Begin: `date -R`" > "${TEMPDIR}"/"${BUILD}"/log.txt
- # Generating image
- make-live ${LIVE_OPTIONS} >> "${TEMPDIR}"/"${BUILD}"/log.txt 2>&1
- ERROR="${?}"
-
- DATE_END="`date -R`"
-
- # Creating image directory
- mkdir -p "${DESTDIR}"/"${BUILD}"
-
- echo "End: ${DATE_END}" >> "${TEMPDIR}"/"${BUILD}"/log.txt
-
if [ "${?}" = "0" ]
then
Modified: dists/trunk/live-webbuilder/live-webbuilder
===================================================================
--- dists/trunk/live-webbuilder/live-webbuilder 2007-05-22 21:16:11 UTC (rev 1618)
+++ dists/trunk/live-webbuilder/live-webbuilder 2007-05-22 21:20:39 UTC (rev 1619)
@@ -24,7 +24,7 @@
# Setting static variables
VERSION="0.2.7"
-HTML="/usr/share/live-webbuilder/html"
+TEMPLATES="/usr/share/live-webbuilder/templates"
TEMPDIR="/tmp/live-webbuilder"
# Sending http header
@@ -32,13 +32,13 @@
echo
# Sending html header
-cat "${HTML}"/header.html
+cat "${TEMPLATES}"/header.html
# CGI
if [ -z "${QUERY_STRING}" ]
then
# Sending html form
- cat "${HTML}"/form.html
+ cat "${TEMPLATES}"/form.html
else
# Converting spaces: sed "s/+/ /g"
# Converting '@': sed "s/%40/@/g"
@@ -70,7 +70,7 @@
-e "s/PACKAGES/${PACKAGES}/" \
-e "s/FILESYSTEM/${FILESYSTEM}/" \
-e "s/ISO_VOLUME/${ISO_VOLUME}/" \
- "${HTML}"/build.html
+ "${TEMPLATES}"/build.html
# Creating temporary directory
if [ ! -d "${TEMPDIR}" ]
@@ -97,4 +97,4 @@
fi
-sed -e "s/VERSION/${VERSION}/" "${HTML}"/footer.html
+sed -e "s/VERSION/${VERSION}/" "${TEMPLATES}"/footer.html
Modified: dists/trunk/live-webbuilder/templates/header.html
===================================================================
--- dists/trunk/live-webbuilder/templates/header.html 2007-05-22 21:16:11 UTC (rev 1618)
+++ dists/trunk/live-webbuilder/templates/header.html 2007-05-22 21:20:39 UTC (rev 1619)
@@ -39,5 +39,5 @@
</div>
<div id="maincontent" style="margin: 0 0 0 0;">
- <h1>This is the autobuild web-interface of the <a href="http://debian-live.alioth.debian.org/">Debian Live</a> project.</h1>
+ <h1>This is the webbuilder of the <a href="http://debian-live.alioth.debian.org/">Debian Live</a> project.</h1>
</div>
Added: dists/trunk/live-webbuilder/templates/mail.txt
===================================================================
--- dists/trunk/live-webbuilder/templates/mail.txt (rev 0)
+++ dists/trunk/live-webbuilder/templates/mail.txt 2007-05-22 21:20:39 UTC (rev 1619)
@@ -0,0 +1,20 @@
+Subject: Debian Live Webbuilder - Build BUILD
+From: Debian Live Webbuilder <debian-live-devel at lists.alioth.debian.org>
+To: EMAIL
+
+Hi,
+
+this is the automatic webbuilder of the Debian Live project
+<http://debian-live.alioth.debian.org/>.
+
+Your build with the ID BUILD has been started at:
+DATE_START
+
+and ended at:
+DATE_END
+
+You can download the images at:
+<http://SERVER/BUILD/>
+
+Have fun,
+the Debian Live team
More information about the Debian-live-changes
mailing list