Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

build.gradle.kts - import of java-classes fails in IntelliJ- Any hint? #3

Closed
Gubaer opened this issue Apr 14, 2018 · 2 comments
Closed

Comments

@Gubaer
Copy link
Contributor

Gubaer commented Apr 14, 2018

Hi

when I import the gradle-josm-plugin in IntelliJ, imports for java classes like java.time.Duration in build.gradle.kts don't work. In kotlin files they don't work either.

I googled but I didn't come up with a solution.

Do you use IntelliJ too? Did you have the same problem? Do you have a workaround?

Thanks in advance!

@floscher
Copy link
Owner

Yes, I also use IntelliJ idea. But I didn't encounter this issue before.

If it is only classes from the JDK, it is probably the issue that IntelliJ can't find the JDK.
Does it only affect Kotlin files or also Java files?
Make sure that under File › Project Structure… › Project Settings › Project the project SDK is set correctly.
Under File › Project Structure… › Platform Settings › SDKs you can inspect the details of the available SDK choices or add a new one.

Does that already help?

@Gubaer
Copy link
Contributor Author

Gubaer commented Apr 15, 2018

Thanks!

I had to manually add the $JAVA_HOME/jre/lib/rt.jar to the SDKs classpath. Seems to be fixed now.

@Gubaer Gubaer closed this as completed Apr 15, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants