I'm using IntelliJ IDEA Community 2020.2.3.
My project is built around Kotlin 1.3.30 and Java 11.
I've upgraded one of my dependecy to java 11 too, and after that, the IDE shows the dependency under "External Libraries", it build the app without errors, Maven build it from terminal without error, but the IDE shows unresolved references on each occurrency of the classes, functions and imports of that library.
I already tried to empty the cache or deleting idea files and importing again the project, but none of those worked.
Any tips?
You can use CTRL+SHIFT+A and look for Load Maven Changes or CTRL+SHIRT+O to do the same thing
Related
I have checked out a gradle project in eclipse but it is not able to recognise any annotation.Foe every annotation in each file it says
Configuration cannot be resolved to a
type
where configuration is annotation.
and all imports corresponding to annotation are also failing with following error:
The import org.springframework cannot be resolved
Entire project with all files is filled with error. But there is no such problem like this in Intellij for same project. Which setting am I missing for Eclipse ?
gradle build works fine although
From my experience, I did not see a checkout option in Eclipse for a Gradle project. I'm using Eclipse version 2019-06 (4.12.0). You need to check out the project in to your local file system and then do an import of the existing project as a Gradle Project.
Things to Note:
Make sure you have the Gradle buildship plugin installed in your Eclipse. (The plugin I use. Buildship: Eclipse Plug-ins for Gradle, provided as part of the Gradle Platform.)
Go to File --> Import. When a pop up box opens, scroll down to Gradle and select Existing Gradle project.
This Way Eclipse recognises the Gradle Project.
I am trying to open this module in Intellij:
https://github.com/eugenp/tutorials/tree/master/javaxval
The steps followed by me:
Go to required directory javaxval/ in my local and
mvn clean install.
Open the pom.xml inside javaxval/ and open it as a project.
But Intellij is not syncing with the libraries mentioned in pom.xml as I can see in libraries section in Project Structure settings. Also, because of that, I can see lot of compilation errors.
Any idea what is the issue I am facing and how can I fix it?
This project imports and builds fine in IntelliJ IDEA 2019.2.2 version using the bundled Maven 3.6.1 for importing and JDK 1.8.
If it doesn't import/build for you, perform the diagnostics and check the logs as described in this answer. Make sure the parent pom file is present in the directory tree on your disk.
I know other people have had this problem, but I can't get it to work.
I imported a project from a git and I get an error saying "Project is not a Java project" when adding a class and it doesn't show up in the run config. Project here if it is something wrong with the project and not eclipse. I've heard answers to this with project facet and maven, but I don't have either.
I am running the latest version of eclipse and clean installed it today
The error should be "“Source folder is not a Java project”".
Check the content of your .project and .classpath.
You can modify the .project to add the org.eclipse.jdt.core.javanature manually.
(But adding the java facet should be the recommended way)
regarding the lack of Java facet, make sure your Eclipse has the right Java version support, as described here.
a .project and .classpath can be manually generated or copied from another simple Java Eclispe project.
I have just switched to Ubuntu and I've installed IntelliJ IDEA 14 Community Edition. When I imported my existing project, I found that IntelliJ can't seem to find any of the LibGDX dependencies. I installed Gradle beforehand. I've tried using the Gradle wrapper included with the IntelliJ project to and saying ./gradlew --refresh-dependencies, but this doesn't seem to do much of anything. My external TweenEngine packages were loaded just fine. It seems to only be with the LibGDX packages that IntelliJ is having a problem with. I do not wish to have IntelliJ see my project as a Gradle Project, as then it will have to sync. I prefer to do things myself in that regard.
My guess is that Gradle isn't installing the LibGDX dependencies, but I'm not entirely sure why that would be happening. Shouldn't ./gradlew --refresh-dependencies install them? The errors I get are all the same as this one, just with different package names and different line numbers:
Error:(7, 24) java: package com.badlogic.gdx does not exist
The line numbers correlate to my LibGDX class imports, so this is what leads me to believe that Gradle is not installing the dependencies.
When I imported the project, I selected the build.gradle file. I have the local.properties file pointing to a valid Android SDK.
If you want a specific look at the project and would like more detail than I have provided, feel free to check out the source code: http://bitbucket.org/Sonic2kk/mr.-ballguy/
What could be causing these errors and how can I correct them?
Try installing the android sdk. If that doesn't work, try reinstalling IntelliJ.
Also, try linking your IntelliJ project to IntelliJ's Gradle plugin.
I use Maven and CouchDB. I put a CouchDB java library dependency in pom.xml and recompile using maven. I see that files get downloaded and the compilation succeeds with no error, but IntelliJ that I use can't find this library or its classes.
I used ektorp, couchdb4j and jcouchdb, but had the same problem. Any help?
If you have opened the project by using [File]->[Open Project...] and then point on the pom.xml then IntelliJ will keep track on changes/updates in the pom.
Do not use the maven-idea-plugin since it is obsolete, last changes are from 2008.
Have a look into a working example and compare it with yours https://github.com/softberries/woodstoxex (couchdb branch), for pure MFN project you can create an IntelliJ project using 'from existing model' option and selecting maven from the list