Make javaconfig.json optional and try to read other config files
See original GitHub issueEclipse generates a .project for a java project. The presence of this file could also indicate the root of a Java project. Along with it, Eclipse generates a .classpath, which is an XML file like this:
<?xml version="1.0" encoding="UTF-8"?>
<classpath>
<classpathentry kind="src" path="src"/>
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
<classpathentry kind="con" path="org.eclipse.jdt.junit.JUNIT_CONTAINER/4"/>
<classpathentry kind="output" path="bin"/>
</classpath>
It contains both the sourcePath setting (<classpathentry kind="src"/>), the outputDirectory (<classpathentry kind="output"/>) and the actual class paths (<classpathentry kind="con">). Eclipse does not have a feature to automatically export these into a text file this extension understands, support for this file would make it super easy to contribute to projects that use Eclipse.
Similarly, maybe we can take the presence of a pom.xml as the indication of a java project root aswell and get classpaths for Maven projects directly from the extension without someone having to add this configuration to their pom.xml?
Would do a PR 😃
Issue Analytics
- State:
- Created 7 years ago
- Comments:13 (7 by maintainers)

Top Related StackOverflow Question
pom.xml is now read automatically: https://github.com/georgewfraser/vscode-javac/commit/ea0a36887374ee22e06a2009a602bcd5a479591a
@felixfbecker @xastor reading eclipse .project would be similar, PR welcome
I would suggest starting simple: a separate source file. If we make some good progress, it can be spun off as a separate module later.