@@ -4,7 +4,7 @@
5# For more information, see https://github.com/haskell-CI/haskell-ci
5# For more information, see https://github.com/haskell-CI/haskell-ci
7−# version: 0.9.20191209
7+# version: 0.9.20200110
9version: ~> 1.0
9version: ~> 1.0
10language: c
10language: c
@@ -73,26 +73,8 @@ before_install:
73 - TOP=$(pwd)
73 - TOP=$(pwd)
74 - "HCNUMVER=$(${HC} --numeric-version|perl -ne '/^(\\d+)\\.(\\d+)\\.(\\d+)(\\.(\\d+))?$/; print(10000 * $1 + 100 * $2 + ($3 == 0 ? $5 != 1 : $3))')"
74 - "HCNUMVER=$(${HC} --numeric-version|perl -ne '/^(\\d+)\\.(\\d+)\\.(\\d+)(\\.(\\d+))?$/; print(10000 * $1 + 100 * $2 + ($3 == 0 ? $5 != 1 : $3))')"
75 - echo $HCNUMVER
75 - echo $HCNUMVER
76− - CABAL="$CABAL -vnormal+nowrap+markoutput"
76+ - CABAL="$CABAL -vnormal+nowrap"
77 - set -o pipefail
77 - set -o pipefail
79− echo 'function blue(s) { printf "\033[0;34m" s "\033[0m " }' >> .colorful.awk
80− echo 'BEGIN { state = "output"; }' >> .colorful.awk
81− echo '/^-----BEGIN CABAL OUTPUT-----$/ { state = "cabal" }' >> .colorful.awk
82− echo '/^-----END CABAL OUTPUT-----$/ { state = "output" }' >> .colorful.awk
83− echo '!/^(-----BEGIN CABAL OUTPUT-----|-----END CABAL OUTPUT-----)/ {' >> .colorful.awk
84− echo ' if (state == "cabal") {' >> .colorful.awk
85− echo ' print blue($0)' >> .colorful.awk
86− echo ' } else {' >> .colorful.awk
87− echo ' print $0' >> .colorful.awk
88− echo ' }' >> .colorful.awk
89− echo '}' >> .colorful.awk
92− color_cabal_output () {
93− awk -f $TOP/.colorful.awk
95− - echo text | color_cabal_output
97 - ${CABAL} --version
79 - ${CABAL} --version
98 - echo "$(${HC} --version) [$(${HC} --print-project-git-commit-id 2> /dev/null || echo '?')]"
80 - echo "$(${HC} --version) [$(${HC} --print-project-git-commit-id 2> /dev/null || echo '?')]"
@@ -133,8 +115,9 @@ install:
133 - cat $CABALHOME/config
115 - cat $CABALHOME/config
134 - rm -fv cabal.project cabal.project.local cabal.project.freeze
116 - rm -fv cabal.project cabal.project.local cabal.project.freeze
135 - travis_retry ${CABAL} v2-update -v
117 - travis_retry ${CABAL} v2-update -v
118+ - if ! $GHCJS ; then (cd /tmp && ${CABAL} v2-install $WITHCOMPILER -j2 doctest --constraint='doctest ==0.16.2.*') ; fi
136− - if $GHCJS ; then (cd /tmp && ${CABAL} v2-install -w ghc-8.4.4 cabal-plan --constraint='cabal-plan ^>=0.6.0.0' --constraint='cabal-plan +exe' | color_cabal_output) ; fi
119+ - if $GHCJS ; then (cd /tmp && ${CABAL} v2-install -w ghc-8.4.4 cabal-plan --constraint='cabal-plan ^>=0.6.0.0' --constraint='cabal-plan +exe') ; fi
137− - if $GHCJS ; then (cd /tmp && ${CABAL} v2-install -w ghc-8.4.4 hspec-discover | color_cabal_output) ; fi
120+ - if $GHCJS ; then (cd /tmp && ${CABAL} v2-install -w ghc-8.4.4 hspec-discover) ; fi
138 # Generate cabal.project
121 # Generate cabal.project
139 - rm -rf cabal.project cabal.project.local cabal.project.freeze
122 - rm -rf cabal.project cabal.project.local cabal.project.freeze
140 - touch cabal.project
123 - touch cabal.project
@@ -212,14 +195,14 @@ install:
212 - if [ -f "doc/cookbook/structuring-apis/configure.ac" ]; then (cd "doc/cookbook/structuring-apis" && autoreconf -i); fi
195 - if [ -f "doc/cookbook/structuring-apis/configure.ac" ]; then (cd "doc/cookbook/structuring-apis" && autoreconf -i); fi
213 - if [ -f "doc/cookbook/using-custom-monad/configure.ac" ]; then (cd "doc/cookbook/using-custom-monad" && autoreconf -i); fi
196 - if [ -f "doc/cookbook/using-custom-monad/configure.ac" ]; then (cd "doc/cookbook/using-custom-monad" && autoreconf -i); fi
214 - if [ -f "doc/cookbook/using-free-client/configure.ac" ]; then (cd "doc/cookbook/using-free-client" && autoreconf -i); fi
197 - if [ -f "doc/cookbook/using-free-client/configure.ac" ]; then (cd "doc/cookbook/using-free-client" && autoreconf -i); fi
215− - ${CABAL} v2-freeze $WITHCOMPILER ${TEST} ${BENCH} | color_cabal_output
198+ - ${CABAL} v2-freeze $WITHCOMPILER ${TEST} ${BENCH}
216 - "cat cabal.project.freeze | sed -E 's/^(constraints: *| *)//' | sed 's/any.//'"
199 - "cat cabal.project.freeze | sed -E 's/^(constraints: *| *)//' | sed 's/any.//'"
217 - rm cabal.project.freeze
200 - rm cabal.project.freeze
219 - DISTDIR=$(mktemp -d /tmp/dist-test.XXXX)
202 - DISTDIR=$(mktemp -d /tmp/dist-test.XXXX)
220 # Packaging...
203 # Packaging...
221 - echo 'Packaging...' && echo -en 'travis_fold:start:sdist\\r'
204 - echo 'Packaging...' && echo -en 'travis_fold:start:sdist\\r'
222− - ${CABAL} v2-sdist all | color_cabal_output
205+ - ${CABAL} v2-sdist all
223 - echo -en 'travis_fold:end:sdist\\r'
206 - echo -en 'travis_fold:end:sdist\\r'
224 # Unpacking...
207 # Unpacking...
225 - echo 'Unpacking...' && echo -en 'travis_fold:start:unpack\\r'
208 - echo 'Unpacking...' && echo -en 'travis_fold:start:unpack\\r'
@@ -335,15 +318,29 @@ script:
335 # Building with tests and benchmarks...
318 # Building with tests and benchmarks...
336 - echo 'Building with tests and benchmarks...' && echo -en 'travis_fold:start:build-everything\\r'
319 - echo 'Building with tests and benchmarks...' && echo -en 'travis_fold:start:build-everything\\r'
337 # build & run tests, build benchmarks
320 # build & run tests, build benchmarks
338− - ${CABAL} v2-build $WITHCOMPILER ${TEST} ${BENCH} all | color_cabal_output
321+ - ${CABAL} v2-build $WITHCOMPILER ${TEST} ${BENCH} all
339 - echo -en 'travis_fold:end:build-everything\\r'
322 - echo -en 'travis_fold:end:build-everything\\r'
340 # Testing...
323 # Testing...
341− - if ! $GHCJS ; then ${CABAL} v2-test $WITHCOMPILER ${TEST} ${BENCH} all | color_cabal_output ; fi
324+ - if ! $GHCJS ; then ${CABAL} v2-test $WITHCOMPILER ${TEST} ${BENCH} all ; fi
342 - if $GHCJS ; then cabal-plan list-bins '*:test:*' | while read -r line; do testpkg=$(echo "$line" | perl -pe 's/:.*//'); testexe=$(echo "$line" | awk '{ print $2 }'); echo "testing $textexe in package $textpkg"; (cd "$(pkgdir $testpkg)" && nodejs "$testexe".jsexe/all.js); done ; fi
325 - if $GHCJS ; then cabal-plan list-bins '*:test:*' | while read -r line; do testpkg=$(echo "$line" | perl -pe 's/:.*//'); testexe=$(echo "$line" | awk '{ print $2 }'); echo "testing $textexe in package $textpkg"; (cd "$(pkgdir $testpkg)" && nodejs "$testexe".jsexe/all.js); done ; fi
327+ - echo 'Doctest...' && echo -en 'travis_fold:start:doctest\\r'
328+ - perl -i -e 'while (<ARGV>) { print unless /package-id\s+(base-compat-batteries)-\d+(\.\d+)*/; }' .ghc.environment.*
329+ - if ! $GHCJS ; then (cd ${PKGDIR_servant} && doctest src) ; fi
330+ - if ! $GHCJS ; then (cd ${PKGDIR_servant_client} && doctest src) ; fi
331+ - if ! $GHCJS ; then (cd ${PKGDIR_servant_client_core} && doctest src) ; fi
332+ - if ! $GHCJS ; then (cd ${PKGDIR_servant_http_streams} && doctest src) ; fi
333+ - if ! $GHCJS ; then (cd ${PKGDIR_servant_docs} && doctest src) ; fi
334+ - if ! $GHCJS ; then (cd ${PKGDIR_servant_foreign} && doctest src) ; fi
335+ - if ! $GHCJS ; then (cd ${PKGDIR_servant_server} && doctest src) ; fi
336+ - if ! $GHCJS ; then (cd ${PKGDIR_servant_machines} && doctest src) ; fi
337+ - if ! $GHCJS ; then (cd ${PKGDIR_servant_conduit} && doctest src) ; fi
338+ - if ! $GHCJS ; then (cd ${PKGDIR_servant_pipes} && doctest src) ; fi
339+ - echo -en 'travis_fold:end:doctest\\r'
343 # haddock...
340 # haddock...
344 - echo 'haddock...' && echo -en 'travis_fold:start:haddock\\r'
341 - echo 'haddock...' && echo -en 'travis_fold:start:haddock\\r'
345− - if ! $GHCJS ; then ${CABAL} v2-haddock $WITHCOMPILER --with-haddock $HADDOCK ${TEST} ${BENCH} all | color_cabal_output ; fi
342+ - if ! $GHCJS ; then ${CABAL} v2-haddock $WITHCOMPILER --with-haddock $HADDOCK ${TEST} ${BENCH} all ; fi
346 - echo -en 'travis_fold:end:haddock\\r'
343 - echo -en 'travis_fold:end:haddock\\r'
348−# REGENDATA ("0.9.20191209",["--config=cabal.haskell-ci","--output=.travis.yml","cabal.project"])
345+# REGENDATA ("0.9.20200110",["--config=cabal.haskell-ci","--output=.travis.yml","cabal.project"])