From 39d81235fdfb1affe5a034f072857dfe32abab35 Mon Sep 17 00:00:00 2001 From: Kailuo Wang Date: Tue, 5 Dec 2017 14:40:50 -0500 Subject: [PATCH 1/6] improve build by not displaying each success test --- build.sbt | 5 ++++- scripts/travis-publish.sh | 2 ++ 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/build.sbt b/build.sbt index 49686f5347..966934882d 100644 --- a/build.sbt +++ b/build.sbt @@ -82,7 +82,10 @@ lazy val commonJsSettings = Seq( ) lazy val commonJvmSettings = Seq( - testOptions in Test += Tests.Argument(TestFrameworks.ScalaTest, "-oDF") + testOptions in Test += { + val flag = if ((isTravisBuild in Global).value) "-oCI" else "-oDF" + Tests.Argument(TestFrameworks.ScalaTest, flag) + } ) lazy val includeGeneratedSrc: Setting[_] = { diff --git a/scripts/travis-publish.sh b/scripts/travis-publish.sh index ce542848d9..d2d78c40da 100755 --- a/scripts/travis-publish.sh +++ b/scripts/travis-publish.sh @@ -1,5 +1,7 @@ #!/bin/bash +set -e + # Build Overview: # The overall build is split into a number of parts # 1. The build for coverage is performed. This: From 0b70fce2cc32701107e4353f6360376834be97c2 Mon Sep 17 00:00:00 2001 From: Kailuo Wang Date: Tue, 5 Dec 2017 14:52:05 -0500 Subject: [PATCH 2/6] improve travis publish --- scripts/travis-publish.sh | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/scripts/travis-publish.sh b/scripts/travis-publish.sh index d2d78c40da..f9289f5091 100755 --- a/scripts/travis-publish.sh +++ b/scripts/travis-publish.sh @@ -1,6 +1,5 @@ #!/bin/bash -set -e # Build Overview: # The overall build is split into a number of parts @@ -37,15 +36,12 @@ free_js="$sbt_cmd validateFreeJS" js="$core_js && $free_js && $kernel_js" jvm="$sbt_cmd coverage validateJVM coverageReport && codecov" -sbt ;coreJVM/publishLocal;freeJVM/publishLocal -cd scalafix -sbt tests/test -cd .. +scalafix="$sbt_cmd ';coreJVM/publishLocal;freeJVM/publishLocal' && cd scalafix && $sbt_cmd tests/test && cd .." if [[ $JS_BUILD == "true" ]]; then run_cmd="$js" else -run_cmd="$jvm && $sbt_cmd $publish_cmd" +run_cmd="$scalafix && $jvm && $sbt_cmd $publish_cmd" fi eval $run_cmd From 821919e35602d37149504f4f5f32062365f91175 Mon Sep 17 00:00:00 2001 From: Kailuo Wang Date: Tue, 5 Dec 2017 15:04:53 -0500 Subject: [PATCH 3/6] only run scalafix test for 2.12 --- scripts/travis-publish.sh | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/scripts/travis-publish.sh b/scripts/travis-publish.sh index f9289f5091..ae5dee04b1 100755 --- a/scripts/travis-publish.sh +++ b/scripts/travis-publish.sh @@ -36,12 +36,16 @@ free_js="$sbt_cmd validateFreeJS" js="$core_js && $free_js && $kernel_js" jvm="$sbt_cmd coverage validateJVM coverageReport && codecov" -scalafix="$sbt_cmd ';coreJVM/publishLocal;freeJVM/publishLocal' && cd scalafix && $sbt_cmd tests/test && cd .." +if [[ $TRAVIS_SCALA_VERSION == *"2.12"* ]]; then +scalafix="sbt ';coreJVM/publishLocal;freeJVM/publishLocal' && cd scalafix && sbt tests/test && cd .. &&" +else +scalafix = "" +fi if [[ $JS_BUILD == "true" ]]; then run_cmd="$js" else -run_cmd="$scalafix && $jvm && $sbt_cmd $publish_cmd" +run_cmd="$scalafix $jvm && $sbt_cmd $publish_cmd" fi eval $run_cmd From 2554172053525acd52ef98ba51b2a4d629beca6b Mon Sep 17 00:00:00 2001 From: Kailuo Wang Date: Tue, 5 Dec 2017 15:42:49 -0500 Subject: [PATCH 4/6] try to control coursier verbosity --- scripts/travis-publish.sh | 2 ++ 1 file changed, 2 insertions(+) diff --git a/scripts/travis-publish.sh b/scripts/travis-publish.sh index ae5dee04b1..1fae591071 100755 --- a/scripts/travis-publish.sh +++ b/scripts/travis-publish.sh @@ -29,6 +29,8 @@ fi sbt_cmd="sbt ++$TRAVIS_SCALA_VERSION" +set COURSIER_VERBOSITY=0 + core_js="$sbt_cmd validateJS" kernel_js="$sbt_cmd validateKernelJS" free_js="$sbt_cmd validateFreeJS" From 6f3aabbbc0bc0b370ddd30c99dd0a09748f3e36b Mon Sep 17 00:00:00 2001 From: Kailuo Wang Date: Tue, 5 Dec 2017 16:40:58 -0500 Subject: [PATCH 5/6] fix env var --- scripts/travis-publish.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/travis-publish.sh b/scripts/travis-publish.sh index 1fae591071..116403f4a9 100755 --- a/scripts/travis-publish.sh +++ b/scripts/travis-publish.sh @@ -29,7 +29,7 @@ fi sbt_cmd="sbt ++$TRAVIS_SCALA_VERSION" -set COURSIER_VERBOSITY=0 +export COURSIER_VERBOSITY=0 core_js="$sbt_cmd validateJS" kernel_js="$sbt_cmd validateKernelJS" From ec2a853c1cec2d9b865d8be22393e6be865a90a4 Mon Sep 17 00:00:00 2001 From: Kailuo Wang Date: Tue, 5 Dec 2017 16:43:43 -0500 Subject: [PATCH 6/6] fix script --- scripts/travis-publish.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/travis-publish.sh b/scripts/travis-publish.sh index 116403f4a9..768bcd91b2 100755 --- a/scripts/travis-publish.sh +++ b/scripts/travis-publish.sh @@ -41,7 +41,7 @@ jvm="$sbt_cmd coverage validateJVM coverageReport && codecov" if [[ $TRAVIS_SCALA_VERSION == *"2.12"* ]]; then scalafix="sbt ';coreJVM/publishLocal;freeJVM/publishLocal' && cd scalafix && sbt tests/test && cd .. &&" else -scalafix = "" +scalafix="" fi if [[ $JS_BUILD == "true" ]]; then