Bootstrap gradle-wrapper with gradle wrapper scripts

(Stevo Slavić) #1

Consider improving gradle wrapper scripts to download gradle-wrapper.jar when it’s absent.

In Apache project source distributions shipping gradle-wrapper.jar or any kind of binaries is not acceptable. (see and ).

(Justin Ryan) #2

Ideally the gradle command would respect the values in the file, then we wouldn’t need any shell scripts or .jar files to get a reproducible build. The best way to respect that file is the tooling api actually. So, I took an approach where I bundle the tooling api jar into an executable shell script ( I can then run “skipper” instead of any gradlew and still get reproducible builds that uses the distribution that I have specified. I haven’t fully figured out how to bundle this for windows, I guess the principle of respecting the is what counts, so a windows version could be a .bat file and a .jar, that is installed onto the PATH.

I’d like to see Gradleware offer a CLI tool like this. It better mimics how IDEs reads in a project and possible eliminates the requirement of checking in a binary file for reproducible builds.