microsoft / microsoft/vscode-java-dependency
Java project in subdirectory of workspace
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 199
- Forks
- 105
- Avg merge
- 1d 22h
- Merged PRs (30d)
- 27
Description
Hello,
I'm in the same situation as https://github.com/microsoft/vscode-java-dependency/issues/493 and would like to understand how things are supposed to be configured.
I'm having a folder structure like
my-project/ (workspace)
L java-app/
L pom.xml
L frontend/
L some-other-sub-project/
L my-project.code-workspace
My workspace file looks like
{
"folders": [
{
"path": "."
}
],
"launch": {
"configurations": [
{
"type": "java",
"name": "Launch My project java app",
"request": "launch",
"mainClass": "com.example.javaApp.MainClass"
"envFile": "${workspaceFolder}/.env",
"projectName": "java-app",
"args": "--spring.profiles.active=development"
}
],
"compounds": []
}
}
But
- the "Java Projects" section in the explorer is empty
- when running my launch config I'm getting
ConfigError: The project 'newstimeline-server' is not a valid java project.
When I change my workspace to
"folders": [
{
"path": "."
},
{
"path": "java-app"
},
],
then my project is shown in the "Java Projects" section and I can get the launch config to somehow work.
But that seems more like a workaround.
How would the java extension pack expect me to configure this situation?
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Reproduce the reported workspace layout with java-app/pom.xml and the provided .code-workspace launch configuration. Start by investigating how the Java extension discovers projects in nested workspace folders and resolves projectName. Done means the Java Projects view recognizes the nested project without adding java-app as a separate workspace folder, and the launch configuration works consistently.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- java, typescript, vscode
- Domain
- developer-experience, tooling
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100