简体   繁体   中英

Intellj not creating gradle wrapper properties

Issue:

I'm using Intellj to make a Kotlin project with openJDK 14. Upon completion of the project wizard, the IDE tells me Invalid Gradle JDK configuration found . A gradle-wrapper.properies file is not found- it seems to me like it's not created. If I pick a JDK for Gradle to use anyway, an error like this will happen Could not initialize class org.codehaus.groovy.reflection.ReflectionCache

Why does Intellj screw up the gradle build?

Current Fix

I can cd into the folder after this and manually create the wrapper with gradle wrapper . This will create the gradle-wrapper.properties file and the build will then work.

Assumptions

I have gradle 6.5 installed and Intellj projects can be created without gradle. I'm using Intellj out of the box.

Thank you

you can use gradle init command to create gradale-wrapper if it's not automatically added. Follow the link below for more details

https://guides.gradle.org/creating-new-gradle-builds/

梯度初始化

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM