idea的多模块管理方式

1.创建一个Empty Project

在这里插入图片描述

2.创建所需的module,其中创建一个maven-parent父模块

在这里插入图片描述


在这里插入图片描述把父工程maven-parent的packaging标签值设置为pom

3.创建maven子模块

在这里插入图片描述

4.修改编译级别(只需在父module中添加编译插件即可)

    <build>
        <plugins>
            <!--编译插件-->
            <plugin>
                <artifactId>maven-compiler-plugin</artifactId>
                <!--插件的版本-->
                <version>3.8.0</version>
                <!--编译级别-->
                <configuration>
                    <source>1.8</source>
                    <target>1.8</target>
                    <!--编码格式-->
                    <encoding>UTF-8</encoding>
                </configuration>
            </plugin>
        </plugins>
    </build>

猜你喜欢

转载自blog.csdn.net/dl674756321/article/details/89607536
今日推荐