How can I get clean Gradle output on Travis CI?

Ralf

Example output for a normal build on Travis CI using Gradle:

https://travis-ci.org/2m/gradle-travis-test/builds/8579228

Gradle seems to think that the console has the same capabilities as a normal ANSI console, while in reality it only supports some of those features. Specifically, it seems to support colors, but not updating/replacing text (it's append-only).

How can I tell Gradle to use "plain" console output?

Ralf

Gradle automatically detects the terminal type based on the $TERM environment variable (and a few other layers in between). Setting TERM=dumb causes Gradle to use plain console output.

In your .travis.yml file, you should now have something like the following (assuming the Gradle wrapper is used):

install:
  - TERM=dumb ./gradlew assemble

script:
  - TERM=dumb ./gradlew check

For sample output, see this build:

https://travis-ci.org/embarkmobile/zxing-android-minimal/builds/9639517

Collected from the Internet

Please contact [email protected] to delete if infringement.

edited at
0

Comments

0 comments
Login to comment

Related

Can I get Travis CI's status as a json response?

How I can specify the version of JDK for travis CI

How can I run a script as part of a Travis CI build?

How can I compile a project two different ways in Travis CI?

How can I avoid travis-ci "SSL errors"?

How can I install something on Travis CI without a timeout?

How can I precompile assets using Travis CI?

How can I build Visual Studio 2019 projects on Travis CI?

How can I run a custom version of dpl on Travis CI?

How can I make Travis CI use input() in python?

How can I preinstall software on travis-ci?

When using CI, how can I keep my environments clean?

How can I collect the output from CI?

How to build on travis-ci with gradle and cobertura

Travis CI no output

How can I clean up the popen output of my C program?

how to get a clean array as output

How can I run multiple builds, each with a separate script, in Travis CI for a C++ project?

How can I have Travis-CI build my electron app for multiple OSes in parallel?

How can I install a specific node.js version on a PHP container on Travis CI?

How can I use git lfs with Travis CI gh-pages deploy?

How can I sort an HTML table by column containing Travis CI badge status images?

Travis CI + Coverity scan with Gradle

Cache gradle dependencies, Travis CI

Travis CI - android gradle project

How can I get the second line of a string in a clean way?

Can't get sauce labs and travis CI to work

Can I store Jenkins configuration in the project repo (like Travis CI)?

Can I deny travis-ci access to an organization?