JK.Li 登录

发布前版本管理及发布流程

Posted by 2019/3/19 16:37:27  •  Author:JK.Li  • 

一、检查配置:


1、修改主项目pom.xml文件

     <properties>

        <version.module>1.0-SNAPSHOT</version.module>

        <soft.open.version>1.2.7-SNAPSHOT</soft.open.version>

        <java_source_version>1.8</java_source_version>

        <java_target_version>1.8</java_target_version>

        <maven_shade_plugin>1.7.1</maven_shade_plugin>

        <maven_war_plugin_version>3.0.0</maven_war_plugin_version>

        <maven_compiler_plugin_version>3.0</maven_compiler_plugin_version>

        <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>

        <project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>

        <maven.build.timestamp.format>yyyyMMddHHmmss</maven.build.timestamp.format>

    </properties>

   <profiles>

        <profile>

            <id>test</id>

            <properties>

                <profileActive>test</profileActive>

            </properties>

            <activation>

                <activeByDefault>false</activeByDefault>

            </activation>

        </profile>

        <profile>

            <id>product</id>

            <properties>

                <profileActive>product</profileActive>

                <version.module>1.0</version.module>

            </properties>

            <activation>

                <activeByDefault>false</activeByDefault>

            </activation>

        </profile>

    </profiles>




2、替换所有子模块

    <version>${version.module}</version>


3、打包的模块

<build>

        <finalName>softlink-open-gateway-${profileActive}-${maven.build.timestamp}-v${project.release.version}</finalName>

        <plugins>

            <plugin>

                <groupId>org.springframework.boot</groupId>

                <artifactId>spring-boot-maven-plugin</artifactId>

                <configuration>

                    <fork>true</fork>

                </configuration>

            </plugin>

        </plugins>

    </build>


4、打包命令:

call cd..

call mvn clean

echo clean end.....


call mvn package -D maven.test.skip=true -U -P product

echo package end.....


call copy xxx-gateway\target\xxx-gateway-*.jar package\

PAUSE



二、合并代码:

     1、合并代码trunk -> branches -> tags 

     2、执行打包命令

Tagged: package  

Comments (0)  • 

0 评论列表

发表评论

京公网安备 11010702001442号