Gradle Cheat Sheet
The flexible JVM/Android build tool — tasks, daemon, caching, and dependency insight.
Build & Package4 sections · 21 commands
⌘K
Tasks & Lifecycle
7./gradlew buildCompile, test, and assemble (incl. checks)
./gradlew cleanDelete build outputs
./gradlew testRun tests
./gradlew tasksList available tasks
./gradlew assembleJust package, skip tests
./gradlew checkRun verification (tests + lint)
./gradlew --dry-run buildShow what would run
Dependencies
4./gradlew dependenciesResolved dependency list
./gradlew dependencyInsight --dependency slf4j-apiWhy a library is present
./gradlew dependencies --configuration runtimeClasspathOne configuration
./gradlew wrapper --gradle-version 8.7Update the wrapper
Daemon & Performance
6./gradlew --no-daemon buildDon't reuse the daemon
./gradlew --stopStop running daemons
./gradlew --parallel buildParallel module builds
./gradlew --offline buildUse cached dependencies only
./gradlew --info buildInformative logging
gradle --versionInstalled version and JVM
Kotlin DSL
4plugins { id 'java' }Apply an id via the plugins block
dependencies { implementation(...) }Declare a dependency
repositories { mavenCentral() }Resolution repositories
test { useJUnitPlatform() }Enable JUnit 5