redhat-developer / redhat-developer/vscode-java
${project.basedir} in pom.xml interpreted wrongly to a wrong absolute path in Windows 10.
未关闭
还没有人认领这个 Issue。
bug
configuration
Maven
- 主要语言
- TypeScript
- 星标
- 2.3k
- 派生
- 546
- 平均合并
- 20 小时 1 分钟
- 30 天内合并 PR
- 11
描述
Environment
- Operating System: Windows 10
- JDK version: 14
- Visual Studio Code version: 1.63.2
- Java extension version: 0.20.0 (Extension pack)
Steps To Reproduce
- Set
sourceDirectoryinpom.xmlto${project.basedir} - Update project and use the command palette to open
Java: Configure Classpath. - See the result.
- Change
${project.basedir}to${project.basedir}/srcor anyone else. Repeat the steps above and see result.
[Sample project reproducing the error]https://github.com/Berkeley-CS61B/skeleton-sp21/tree/master/lab2setup
Current Result
${project.basedir}is interpreted as a fake absolute path. For example:Users\aoliu\OneDrive\Projects\cs61b-sp21\lab2setupwhich should beC:\Users\aoliu\OneDrive\Projects\cs61b-sp21\lab2setupin Windows 10.${project.basedir}\srcor other path that under the basedir is correctly interpreted. For example:${project.basedir}\srcis interpreted assrc, a relative path.

贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
调研方向
从链接的示例项目开始,在 Windows 10 上使用 Java: Configure Classpath 命令重现该问题。比较 ${project.basedir} 和 ${project.basedir}/src 的解析方式;当 basedir 保留其 Windows 驱动器号并生成正确的 classpath 时,即表示完成。
由索引模型根据 Issue 内容生成。
评估
- 技术栈
- java, typescript
- 领域
- build-system, tooling
- Issue 类型
- 缺陷
- 难度
- 3/5
- 预计耗时
- 1-2 天
- 活跃度
- 停滞
- 描述清晰度
- 基本清楚
- 新手友好度
- 38/100