I have a project that have been worked on eclipse by my coworker, they have it on git and have the ".classpath" and ".project" files on the repository.
I usually use Visual Studio Code and i wanted to use it for the java project as well.
The problem is that the .classpath contains classpathentrys that have been configured with the eclipse "Java Build Path" and contains all the external Jars that we need and also the JRE.
The thing is that the JRE is found without any problem in "org.eclipse.jdt.launching.JRE_CONTAINER", but all the other "org.eclipse.jdt.USER_LIBRARY" can't be found.
The .classpath also contains a output path that uses the "Linked ressources" of eclipse and can't be find as well.
Is there a way to tell vscode what each classpathentry path actually is? a sort of override ?
I know that we can specify the "java.project.referencedLibraries" in the settings.json and i did that but if i keep the .classpath the referencedLibraries are ignored on my project.
Even if i delete the .classpath and .project files vscode seem to fail to recognize that it is a java project, so i'm a bit stuck here.
Any help would be appreciated, don't hesitate to ask for more informations if needed
Thanks in advance !
CodePudding user response:
Have you thought of using a gitignore file? https://www.freecodecamp.org/news/gitignore-what-is-it-and-how-to-add-to-repo/#:~:text=gitignore file is a text,all of your Git repositories.
CodePudding user response:
The folder opened by VS Code is used as the workspace, so please open the folder of the Java project correctly. it will identify the java project.