Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我想要的是项目源根目录的父 pom.xml 导入子 pom.xml 文件"on-demand"。使用Maven可以实现吗?假设其他团队成员创建了一个新模块并将子 pom.xml 放入其中,然后在系统构建时,父 pom.xml 会自动导入子模块(无需事先对父 pom.xml 进行修改)。
No, it doesn't work like this. There is no "automatic" discovery of new modules in multi-module projects. You will need to define the relationship between the child and parent poms in the parent pom.