tweak travis-ci configuration

By setting TERM=dumb, it makes Gradle not produce output intended for an interactive terminal,
such as download percentages.  This makes the output in Travis much more readable.

In Java builds, if the Gradle wrapper is detected, Travis by default runs "./gradlew assemble" in the
install phase, and "./gradlew check" in the script phase.  This incurs two startups of Gradle for no
additional benefit.  It's faster to just run "./gradlew build" in the script phase.  "install: true" disables
the default install phase.