summaryrefslogtreecommitdiff
path: root/travis.sh
diff options
context:
space:
mode:
authorJosh Haberman <jhaberman@gmail.com>2015-05-16 14:47:34 -0700
committerJosh Haberman <jhaberman@gmail.com>2015-05-16 15:32:38 -0700
commit00c36ece2055bff19c61632730cd04ec72739d1b (patch)
treeeb88a008694c3717f8d0424db81bc73fcea2c653 /travis.sh
parente087947c84ee6b7d86abe9585ee51efee7595a26 (diff)
Upload failing artifacts to S3 for debugging purposes.
Diffstat (limited to 'travis.sh')
-rwxr-xr-xtravis.sh17
1 files changed, 14 insertions, 3 deletions
diff --git a/travis.sh b/travis.sh
index c1028f7..f2ac154 100755
--- a/travis.sh
+++ b/travis.sh
@@ -101,6 +101,20 @@ coverage_after_success() {
coveralls --exclude dynasm --exclude tests --exclude upb/bindings/linux --gcov-options '\-lp'
}
+set -e
+set -x
+
+if [ "$1" == "after_failure" ]; then
+ # Upload failing tree to S3.
+ curl -sL https://raw.githubusercontent.com/travis-ci/artifacts/master/install | bash
+ PATH="$PATH:$HOME/bin"
+ export ARTIFACTS_BUCKET=haberman-upb-travis-artifacts2
+ ARCHIVE=failing-artifacts.tar.gz
+ tar zcvf $ARCHIVE $(git ls-files -o)
+ artifacts upload $ARCHIVE
+ exit
+fi
+
if [ "$1" == "after_success" ] && [ "$UPB_TRAVIS_BUILD" != "coverage" ]; then
# after_success is only used for coverage.
exit
@@ -117,9 +131,6 @@ export USER_CPPFLAGS="-UNDEBUG -DUPB_DEBUG_REFS -DUPB_THREAD_UNSAFE -g"
# Enable verbose build.
export Q=
-set -e
-set -x
-
# Make any compiler warning fail the build.
export UPB_FAIL_WARNINGS=true
generated by cgit on debian on lair
contact matthew@masot.net with questions or feedback