Hot to use wrapper build file and gradlew

hi, trying to add gradle to an existing eclipse luna project.

got sidetracked when i downloaded gradle 2.3 and fixed GRADLE_HOME.

gradle -v works fine.

following the, i run gradle with: task wrapper(type: Wrapper) { gradleVersion = ‘2.3’ }

works fine (but only a few version of 1.x are in C:\Users\ray.gradle\wrapper\dists).

gradlew says command not found on windoze :frowning:

i am confused.

what am i doing wrong?


If you’re on windows, you have to use gradlew.bat when you’re in a command prompt (cmd) unless you have something like Git Bash. If you don’t have ‘.’ on your PATH, you’ll have to use ./gradlew

When you run ‘gradle wrapper’ it should generate the gradlew, gradlew.bat, gradle directory files.

The idea is that someone initially has Gradle installed, they generate the wrapper files and check them in. Then everyone else can use gradlew to download/use the correct version of Gradle.

oh, duh!

works like a charm.