What is the difference between running ./gradlew and ./gradlew build?

Viewed 31

What is the difference between running ./gradlew and ./gradlew build?

Both seem to be build the project, but ./gradlew ignore test and compileTest task. When test has problem, ./gradlew build is failed, but ./gradlew is succeeded.

1 Answers

./gradlew is invoking the Gradle Wrapper with no task specified. By default, this displays Gradle version information. This behavior can be changed by settings a default task

./gradlew build invokes the Gradle Wrapper with the task named build. Therefore, the build task executes along with any of its task dependencies.

Related