<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0"
         xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
         xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
    <parent>
        <artifactId>casic-metering</artifactId>
        <groupId>com.casic</groupId>
        <version>2.0.0</version>
    </parent>
    <modelVersion>4.0.0</modelVersion>

    <artifactId>casic-metering-api</artifactId>
    <packaging>jar</packaging>
    <description>casic web api启动入口</description>

    <dependencies>
        <dependency>
            <!--  依赖其他module -->
            <groupId>com.casic</groupId>
            <artifactId>casic-metering-service</artifactId>
            <version>2.0.0</version>
        </dependency>
        <dependency>
            <!--  依赖其他module -->
            <groupId>com.casic</groupId>
            <artifactId>casic-metering-job</artifactId>
            <version>2.0.0</version>
        </dependency>
        <dependency>
            <groupId>org.springframework.boot</groupId>
            <artifactId>spring-boot-starter-actuator</artifactId>
            <exclusions>
                <exclusion>
                    <groupId>io.micrometer</groupId>
                    <artifactId>micrometer-core</artifactId>
                </exclusion>
            </exclusions>
        </dependency>
        <dependency>
            <groupId>org.springframework.boot</groupId>
            <artifactId>spring-boot-starter-jdbc</artifactId>
        </dependency>
        <!--基础包依赖-->
        <dependency>
            <groupId>com.casic</groupId>
            <artifactId>casic-core</artifactId>
            <version>${core.version}</version>
        </dependency>
        <dependency>
            <groupId>com.casic</groupId>
            <artifactId>casic-admin-support</artifactId>
            <version>${admin.version}</version>
        </dependency>
        <dependency>
            <groupId>com.casic</groupId>
            <artifactId>casic-file-support</artifactId>
            <version>${admin.version}</version>
        </dependency>
        <dependency>
            <groupId>com.casic</groupId>
            <artifactId>casic-export-support</artifactId>
            <version>${extension.version}</version>
        </dependency>
        <dependency>
            <groupId>com.casic</groupId>
            <artifactId>casic-file</artifactId>
            <version>${admin.version}</version>
        </dependency>
        <dependency>
            <groupId>com.casic</groupId>
            <artifactId>casic-admin-core</artifactId>
            <version>${admin.version}</version>
            <exclusions>
                <exclusion>
                    <groupId>io.springfox</groupId>
                    <artifactId>springfox-swagger-ui</artifactId>
                </exclusion>
            </exclusions>
        </dependency>
        <dependency>
            <groupId>org.springframework.boot</groupId>
            <artifactId>spring-boot-starter-web</artifactId>
            <version>${boot.version}</version>
        </dependency>
        <dependency>
            <groupId>mysql</groupId>
            <artifactId>mysql-connector-java</artifactId>
            <version>${mysql.driver.version}</version>
        </dependency>
        <dependency>
            <groupId>com.casic</groupId>
            <artifactId>casic-area-starter</artifactId>
            <version>${admin.version}</version>
        </dependency>
        <!--spring boot依赖-->
        <dependency>
            <groupId>org.springframework.boot</groupId>
            <artifactId>spring-boot-starter-tomcat</artifactId>
        </dependency>
        <dependency>
            <groupId>org.springframework.boot</groupId>
            <artifactId>spring-boot-starter-test</artifactId>
        </dependency>
        <dependency>
            <groupId>junit</groupId>
            <artifactId>junit</artifactId>
        </dependency>
        <dependency>
            <groupId>org.flowable</groupId>
            <artifactId>flowable-spring-boot-starter</artifactId>
            <version>${flowable.version}</version>
            <exclusions>
                <exclusion>
                    <groupId>org.flowable</groupId>
                    <artifactId>flowable-spring-boot-starter-app</artifactId>
                </exclusion>
                <exclusion>
                    <groupId>org.flowable</groupId>
                    <artifactId>flowable-form-spring-configurator</artifactId>
                </exclusion>
                <exclusion>
                    <groupId>org.flowable</groupId>
                    <artifactId>flowable-idm-spring-configurator</artifactId>
                </exclusion>
                <exclusion>
                    <artifactId>mybatis</artifactId>
                    <groupId>org.mybatis</groupId>
                </exclusion>
            </exclusions>
        </dependency>
        <dependency>
            <groupId>org.flowable</groupId>
            <artifactId>flowable-bpmn-model</artifactId>
            <version>${flowable.version}</version>
            <scope>compile</scope>
        </dependency>
        <dependency>
            <groupId>org.flowable</groupId>
            <artifactId>flowable-json-converter</artifactId>
            <version>${flowable.version}</version>
            <scope>compile</scope>
        </dependency>
        <dependency>
            <groupId>org.flowable</groupId>
            <artifactId>flowable-bpmn-converter</artifactId>
            <version>${flowable.version}</version>
            <scope>compile</scope>
        </dependency>
        <dependency>
            <!-- 自动布局jar 包-->
            <groupId>org.flowable</groupId>
            <artifactId>flowable-bpmn-layout</artifactId>
            <version>${flowable.version}</version>
        </dependency>
        <!-- 热部署，optional选项是为了防止将devtools依赖传递到其他模块中。当开发者将应用打包运行后，devtools 会被自动禁用 -->
        <dependency>
            <groupId>org.springframework.boot</groupId>
            <artifactId>spring-boot-devtools</artifactId>
            <optional>true</optional>
        </dependency>
    </dependencies>
    <build>
        <plugins>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-jar-plugin</artifactId>
                <version>${maven.jar.plugin.version}</version>
                <configuration>
                    <excludes>
                        <!--注意从编译结果目录开始算目录结构-->
                        <exclude>/config/*-*.yml</exclude>
                        <exclude>**/MockController.class</exclude>
                    </excludes>
                    <archive>
                        <manifest>
                            <mainClass>com.casic.missiles.CasicApiApplication</mainClass>
                            <addClasspath>true</addClasspath>
                            <classpathPrefix>./</classpathPrefix>
                        </manifest>
                    </archive>
                </configuration>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-assembly-plugin</artifactId>
                <version>${maven.assembly.plugin.version}</version>
                <executions>
                    <execution>
                        <id>make-assembly</id>
                        <phase>package</phase>
                        <goals>
                            <goal>single</goal>
                        </goals>
                    </execution>
                </executions>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-war-plugin</artifactId>
                <version>${maven.war.plugin.version}</version>
            </plugin>
            <plugin>
                <groupId>org.springframework.boot</groupId>
                <artifactId>spring-boot-maven-plugin</artifactId>
                <configuration>
                    <!-- 没有该配置，devtools 不生效 -->
                    <fork>true</fork>
                    <addResources>true</addResources>
                </configuration>
            </plugin>
        </plugins>
        <resources>
            <resource>
                <directory>src/main/resources</directory>
                <excludes>
                    <!--注意从编译结果目录开始算目录结构-->
                    <exclude>/config/*/*</exclude>
                    <exclude>/config/*-*.yml</exclude>
                </excludes>
                <filtering>true</filtering>
            </resource>
            <resource>
                <directory>src/main/java</directory>
                <includes>
                    <include>**/*.xml</include>
                </includes>
                <filtering>true</filtering>
            </resource>
        </resources>
    </build>
</project>