[Qa-jenkins-scm] [jenkins.debian.net] 01/01: reproducible LEDE: move `git log -1 > .html` to node_document_environment
Holger Levsen
holger at layer-acht.org
Tue Jun 27 22:42:08 UTC 2017
This is an automated email from the git hooks/post-receive script.
holger pushed a commit to branch master
in repository jenkins.debian.net.
commit 1542df26bd0d4ac34df04528bb6cb4eda8388002
Author: Alexander Couzens <lynxis at fe80.eu>
Date: Wed Jun 28 00:20:14 2017 +0200
reproducible LEDE: move `git log -1 > .html` to node_document_environment
Removes also the garbage in the git commit section
Signed-off-by: Holger Levsen <holger at layer-acht.org>
---
bin/reproducible_lede.sh | 7 +------
bin/reproducible_lede_common.sh | 16 ++++++----------
2 files changed, 7 insertions(+), 16 deletions(-)
diff --git a/bin/reproducible_lede.sh b/bin/reproducible_lede.sh
index 95a2ae0..16254bd 100755
--- a/bin/reproducible_lede.sh
+++ b/bin/reproducible_lede.sh
@@ -31,7 +31,6 @@ case $1 in
openwrt_build |\
openwrt_download |\
openwrt_get_banner |\
- openwrt_get_commit |\
node_create_tmpdirs |\
node_debug |\
node_save_logs |\
@@ -64,7 +63,6 @@ START=$(date +'%s')
TMPBUILDDIR=$(mktemp --tmpdir=/srv/workspace/chroots/ -d -t rbuild-lede-build-${DATE}-XXXXXXXX) # used to build on tmpfs
TMPDIR=$(mktemp --tmpdir=/srv/reproducible-results -d -t rbuild-lede-results-XXXXXXXX) # accessable in schroots, used to compare results
BANNER_HTML=$(mktemp --tmpdir=$TMPDIR)
-GIT_COMMIT=$(mktemp --tmpdir=$TMPDIR)
trap master_cleanup_tmpdirs INT TERM EXIT
cd $TMPBUILDDIR
@@ -238,14 +236,11 @@ write_page " <p>$GOOD_IMAGES ($GOOD_PERCENT_IMAGES%) out of $ALL_IMAGES bu
write_page " These tests were last run on $DATE for version ${OPENWRT_VERSION} using ${DIFFOSCOPE}.</p>"
write_variation_table LEDE
cat $DBD_HTML >> $PAGE
-write_page " <table><tr><th>git commit built</th></tr><tr><td><code>"
-cat $GIT_COMMIT >> $PAGE
-write_page " </code></td></tr></table>"
cat $TOOLCHAIN_HTML >> $PAGE
write_page " </div>"
write_page_footer LEDE
publish_page
-rm -f $DBD_HTML $DBD_GOOD_PKGS_HTML $DBD_BAD_PKGS_HTML $TOOLCHAIN_HTML $BANNER_HTML $GIT_COMMIT
+rm -f $DBD_HTML $DBD_GOOD_PKGS_HTML $DBD_BAD_PKGS_HTML $TOOLCHAIN_HTML $BANNER_HTML
# the end
calculate_build_duration
diff --git a/bin/reproducible_lede_common.sh b/bin/reproducible_lede_common.sh
index 5301c3d..85b0867 100644
--- a/bin/reproducible_lede_common.sh
+++ b/bin/reproducible_lede_common.sh
@@ -79,7 +79,12 @@ node_document_environment() {
local toolchain_html=$tmpdir/toolchain.html
cd $tmpdir/build/source
- echo "<table><tr><th>Target toolchains built</th></tr>" > $toolchain_html
+ cat /dev/null > $toolchain_html
+ echo " <table><tr><th>git commit built</th></tr><tr><td><code>" >> $toolchain_html
+ git log -1 >> $toolchain_html
+ echo " </code></td></tr></table>" >> $toolchain_html
+
+ echo "<table><tr><th>Target toolchains built</th></tr>" >> $toolchain_html
for i in $(ls -1d staging_dir/toolchain*|cut -d "-" -f2-|xargs echo) ; do
echo " <tr><td><code>$i</code></td></tr>" >> $toolchain_html
done
@@ -334,14 +339,6 @@ openwrt_download() {
done
}
-openwrt_get_commit() {
- TMPDIR=$1
- TYPE=$2
- cd $TMPDIR/build/source
- git log -1
-}
-
-
openwrt_get_banner() {
TMPDIR=$1
TYPE=$2
@@ -421,7 +418,6 @@ build_two_times() {
RUN=b1
ssh $GENERIC_NODE1 reproducible_$TYPE node openwrt_build $TYPE $RUN $TARGET $CONFIG $TMPDIR
ssh $GENERIC_NODE1 reproducible_$TYPE node openwrt_get_banner $TMPDIR $TYPE > $BANNER_HTML
- ssh $GENERIC_NODE1 reproducible_$TYPE node openwrt_get_commit $TMPDIR $TYPE > $GIT_COMMIT
# cut away everything before begin and after the end…
# (thats noise generated by the way we run this via reproducible_common.sh)
cat $BANNER_HTML | sed '/===bannerend===/,$d' | tac | sed '/===bannerbegin===/,$d' | tac > $BANNER_HTML
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/qa/jenkins.debian.net.git
More information about the Qa-jenkins-scm
mailing list