-
Notifications
You must be signed in to change notification settings - Fork 399
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
java.project.addToSourcePath
command should be allowed in gradle/maven project
#964
Comments
For Maven and Gradle project, the "truth" comes from the build descriptor. So adding new source folders from the IDE would likely introduce an impedance mismatch with CLI builds, if those folders are not defined as well. So I'd rather prefer we fixed potential issues with jdt.ls not adding source folders when it should, rather than introduce than providing more ways to users to shoot them in the foot |
Closing as the discussion can continue on #1954 . |
This issue is related to #859
https:/eclipse/eclipse.jdt.ls/blob/ca81aa7b935b52c0aff7624fa9f330c832578233/org.eclipse.jdt.ls.core/src/org/eclipse/jdt/ls/core/internal/commands/BuildPathCommand.java#L45
Currently jdt-langserver doesn't allow users to add folder to source path if the project is a Maven/Gradle project which doesn't make sense.
When I open a source file which isn't included in the build path, there isn't any code intelligence at all. Meanwhile I need to modify the build script to add these source folders.
It will be nice if we have code intelligence on these files(even without auto-build) by adding the folder to source path, or can jdt-langserver just treats them as standalone files?
screenshot:
The text was updated successfully, but these errors were encountered: