From 8b109f99811f3dece82c9cd21143db237b6608d7 Mon Sep 17 00:00:00 2001 From: Andreas Dangel Date: Sat, 8 Jul 2017 13:10:32 +0200 Subject: [PATCH] [ci] let's try the quiet option (-q) of maven travis_wait_truncated doesn't work, since the pipes are buffered... --- .travis/build-site.sh | 6 +++--- .travis/build-sonar.sh | 2 +- .travis/common-functions.sh | 15 --------------- 3 files changed, 4 insertions(+), 19 deletions(-) diff --git a/.travis/build-site.sh b/.travis/build-site.sh index 2e7ec21db2..fe2a2b711a 100644 --- a/.travis/build-site.sh +++ b/.travis/build-site.sh @@ -16,11 +16,11 @@ fi # Run the build, truncate output due to Travis log limits echo -e "\n\nExecuting ./mvnw install...\n\n" - travis_wait_truncated ./mvnw install -DskipTests=true -B -V + travis_wait ./mvnw install -DskipTests=true -B -V -q echo -e "Finished executing ./mvnw install\n\n" echo -e "\n\nExecuting ./mvnw site site:stage...\n\n" - travis_wait_truncated ./mvnw site site:stage -Psite -B -V + travis_wait ./mvnw site site:stage -Psite -B -V -q echo -e "Finished executing ./mvnw site site:stage...\n\n" ) @@ -39,6 +39,6 @@ fi ( if [[ "$VERSION" == *-SNAPSHOT && "$TRAVIS_BRANCH" == "master" ]]; then echo -e "\n\nUploading snapshot site...\n\n" - travis_wait_truncated rsync -ah --stats --delete target/pmd-doc-${VERSION}/ ${PMD_SF_USER}@web.sourceforge.net:/home/project-web/pmd/htdocs/snapshot/ + travis_wait rsync -ah --stats --delete target/pmd-doc-${VERSION}/ ${PMD_SF_USER}@web.sourceforge.net:/home/project-web/pmd/htdocs/snapshot/ fi ) diff --git a/.travis/build-sonar.sh b/.travis/build-sonar.sh index c38999bea0..c852ec977b 100644 --- a/.travis/build-sonar.sh +++ b/.travis/build-sonar.sh @@ -13,5 +13,5 @@ fi # Run the build, truncate output due to Travis log limits -travis_wait_truncated ./mvnw clean org.jacoco:jacoco-maven-plugin:prepare-agent package sonar:sonar -Dsonar.host.url=https://sonarqube.com -Dsonar.login=${SONAR_TOKEN} -B -V +travis_wait ./mvnw clean org.jacoco:jacoco-maven-plugin:prepare-agent package sonar:sonar -Dsonar.host.url=https://sonarqube.com -Dsonar.login=${SONAR_TOKEN} -B -V -q diff --git a/.travis/common-functions.sh b/.travis/common-functions.sh index 896d0655aa..6e9c9a8e26 100644 --- a/.travis/common-functions.sh +++ b/.travis/common-functions.sh @@ -27,18 +27,3 @@ function travis_isPush() { return 1 fi } - -# -# Since travis_wait outputs the "Still running" indication into the -# same stream as the command's output, we need to make sure, we -# output these indications to avoid a build timeout. -# But to workaround the log size limit, we shouldn't output everything. -# travis_wait_truncated now outputs the head immediately, while -# only outputting the tail of the log after the command is finished. -# -function travis_wait_truncated() { - local log=$(tempfile) - travis_wait "$@" | tee $log | head -100 - tail -100 $log - rm -f $log -} \ No newline at end of file