From dd66f9c5a2b96889780a5995f1919293c91a624d Mon Sep 17 00:00:00 2001 From: Andreas Dangel Date: Sun, 27 Jan 2019 19:39:31 +0100 Subject: [PATCH] [ci] fix path to travis_wait, more usages of travis_wait --- .travis/build-deploy.sh | 4 +++- .travis/build-doc.sh | 4 ++-- .travis/travis_wait | 2 ++ 3 files changed, 7 insertions(+), 3 deletions(-) diff --git a/.travis/build-deploy.sh b/.travis/build-deploy.sh index 1f209eeaed1..9fb006f1952 100755 --- a/.travis/build-deploy.sh +++ b/.travis/build-deploy.sh @@ -35,10 +35,11 @@ function upload_baseline() { cd target/reports BRANCH_FILENAME="${TRAVIS_BRANCH/\//_}" zip -q -r ${BRANCH_FILENAME}-baseline.zip ${BRANCH_FILENAME}/ - .travis/travis_wait "rsync -avh ${BRANCH_FILENAME}-baseline.zip ${PMD_SF_USER}@web.sourceforge.net:/home/frs/project/pmd/pmd-regression-tester/" + ../../pmd/.travis/travis_wait "rsync -avh ${BRANCH_FILENAME}-baseline.zip ${PMD_SF_USER}@web.sourceforge.net:/home/frs/project/pmd/pmd-regression-tester/" if [ $? -ne 0 ]; then log_error "Error while uploading ${BRANCH_FILENAME}-baseline.zip to sourceforge!" log_error "Please upload manually: https://sourceforge.net/projects/pmd/files/pmd-regression-tester/" + exit 1 else log_success "Successfully uploaded ${BRANCH_FILENAME}-baseline.zip to sourceforge" fi @@ -93,6 +94,7 @@ elif travis_isPush; then if [ $? -ne 0 ]; then log_error "Error while uploading pmd-*-${VERSION}.zip to sourceforge!" log_error "Please upload manually: https://sourceforge.net/projects/pmd/files/pmd/" + exit 1 else log_success "Successfully uploaded pmd-*-${VERSION}.zip to sourceforge" fi diff --git a/.travis/build-doc.sh b/.travis/build-doc.sh index e4ec9c9a9b5..e353986148f 100755 --- a/.travis/build-doc.sh +++ b/.travis/build-doc.sh @@ -35,7 +35,7 @@ ls -lh pmd-doc-${VERSION}.zip if [[ "${TRAVIS_TAG}" != "" || "${VERSION}" == *-SNAPSHOT ]]; then echo -e "\n\n" log_info "Uploading pmd doc distribution to sourceforge..." - rsync -avh pmd-doc-${VERSION}.zip ${PMD_SF_USER}@web.sourceforge.net:/home/frs/project/pmd/pmd/${VERSION}/ + ../.travis/travis_wait "rsync -avh pmd-doc-${VERSION}.zip ${PMD_SF_USER}@web.sourceforge.net:/home/frs/project/pmd/pmd/${VERSION}/" if [ $? -ne 0 ]; then log_error "Couldn't upload pmd-doc-${VERSION}.zip!" log_error "Please upload manually: https://sourceforge.net/projects/pmd/files/pmd/" @@ -48,7 +48,7 @@ ls -lh pmd-doc-${VERSION}.zip if [[ "${VERSION}" == *-SNAPSHOT && "${TRAVIS_BRANCH}" == "master" ]] && has_docs_change; then echo -e "\n\n" log_info "Uploading snapshot site to pmd.sourceforge.net/snapshot..." - travis_wait rsync -ah --stats --delete pmd-doc-${VERSION}/ ${PMD_SF_USER}@web.sourceforge.net:/home/project-web/pmd/htdocs/snapshot/ + ../.travis/travis_wait "rsync -ah --stats --delete pmd-doc-${VERSION}/ ${PMD_SF_USER}@web.sourceforge.net:/home/project-web/pmd/htdocs/snapshot/" if [ $? -ne 0 ]; then log_error "Couldn't upload the snapshot documentation. It won't be current on http://pmd.sourceforge.net/snapshot/" else diff --git a/.travis/travis_wait b/.travis/travis_wait index 013cea97df2..d81dd41089b 100755 --- a/.travis/travis_wait +++ b/.travis/travis_wait @@ -314,6 +314,8 @@ main() { else exit_slowpoke=${exit_force} fi + # Output last couple of lines from $file_log + tail -5 "${file_log}" show_warning "Your given command has terminated with exit code $exit_slowpoke. So do I." exit ${exit_slowpoke}