如何给项目打包啊??

一个maven项目,其中包含js代码,五个模块中有一个是
纯js模块,其他四个maven模块,达成一个jar包该怎么打呢??
img
项目结构如图,网上搜的很多都没办法实现

你们太可怕了一点项目经验都没有吗?
建立一个主pom文件 ,主pom.xml中加入对应模块引用,将这些子模块的jar编译在本地maven厂库中。

< modules>

    < module>port-core</module>
    < module>port-security</module>
    <module>port-dictionary</module>
</modules>

< dependencyManagement>

    < dependencies>
        < dependency>
            < groupId>cn.asiic.port< /groupId>
            < artifactId>port-core< /artifactId>
            < version>${portal.version}< /version>
        < /dependency>

。。。。。。。。
< /dependencies>

在启动模块的pom.xml中引入本地maven库中编译好的的子模块jar打包到启动包jar中来。
< dependencies>
< dependency>
< groupId>cn.asiic.port< /groupId>
< artifactId>port-core< /artifactId>
< /dependency>
< dependency>
< groupId>cn.asiic.port< /groupId>
< artifactId>port-security< /artifactId>
< /dependency>

< /dependencies>

< build>
    < plugins>
        < plugin>
            < groupId>org.springframework.boot < /groupId>
            < artifactId>spring-boot-maven-plugin < /artifactId>
        < /plugin>
    < /plugins>
< /build>

参考这篇文档。

maven的插件里有个jar的插件,点他就自动打包了