summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDiego Elio Pettenò <flameeyes@flameeyes.eu>2012-06-16 16:38:36 +0200
committerDiego Elio Pettenò <flameeyes@flameeyes.eu>2012-06-16 16:38:36 +0200
commit91956ecb040a90128e4578ac7072679b7a760cf7 (patch)
tree6351ab54b4f2a387705061541e0bccf9860aa4ce
parentSend the log to the analysis system whenever a package fails or succeeds. (diff)
downloadflameeyes-tinderbox-91956ecb040a90128e4578ac7072679b7a760cf7.tar.gz
flameeyes-tinderbox-91956ecb040a90128e4578ac7072679b7a760cf7.tar.bz2
flameeyes-tinderbox-91956ecb040a90128e4578ac7072679b7a760cf7.zip
No-op on log sending when the analysis address is unset.
-rwxr-xr-xbashrc12
1 files changed, 8 insertions, 4 deletions
diff --git a/bashrc b/bashrc
index 6ad45d3..f84bb64 100755
--- a/bashrc
+++ b/bashrc
@@ -41,10 +41,14 @@ tinderbox_stats() {
fi
}
-tinderbox_send_log() {
- tar cf - "${PORTAGE_LOG_FILE}" | \
- nc6 --send-only --hold-timeout=0 ${TINDERBOX_ANALYSIS_ADDR}
-}
+if [[ -n "${TINDERBOX_ANALYSIS_ADDR}" ]]; then
+ tinderbox_send_log() {
+ tar cf - "${PORTAGE_LOG_FILE}" | \
+ nc6 --send-only --hold-timeout=0 ${TINDERBOX_ANALYSIS_ADDR}
+ }
+else
+ tinderbox_send_log() { :; }
+fi
tinderbox_success() {
dent_me "${CATEGORY}/${PF} merge #succeded$(tinderbox_stats)"