Executing custom Gradle wrapper script?
Answered
Hi all,
The project I'm working on comes with a custom Gradle wrapper script, gradlew.bat, that - amongst other things - sets environment variables.
What settings do I have to pick in IntelliJ to make sure IntelliJ runs that custom gradlew.bat script from the project's root, instead of any other gradle installation (or wrapper)?
None of the options in IntelliJ's settings really seem to fit the bill:
- The gradle-wrapper.properties option is going to use the gradle\gradle-wrapper.properties file to download a version of gradle and thus won't use the custom wrapper (if I'm not mistaken).
- The 'wrapper' task in Gradle build script seems to download the version specified in the build script, which will also not execute the custom wrapper. (I'm new to Gradle: could this be written in a way to just use the wrapper script present in the project's root? But then, wouldn't Grale be already running by the time those instructions were executed?)
- Finally, the Specified location option can - as per docs - be used to bypass any wrapper and point to an existing installation.
Is there a setting that'll just use the wrapper script that's already in the project's root folder?
Kind regards,
Christian
Please sign in to leave a comment.
Please vote for https://youtrack.jetbrains.com/issue/IDEA-173926.