zoukankan      html  css  js  c++  java
  • 打包组件assembly之package.xml

    形如:

    <assembly>
        <id>deploy</id>
        <formats>
            <format>zip</format>
        </formats>
        <includeBaseDirectory>false</includeBaseDirectory>
        <dependencySets>
            <dependencySet>
                <useProjectArtifact>true</useProjectArtifact>
                <outputDirectory>lib</outputDirectory>
                <includes>
                    <include>*:jar:*</include>
                </includes>
                <excludes>
                    <exclude>*:sources</exclude>
                </excludes>
            </dependencySet>
        </dependencySets>
        <fileSets>
            <fileSet>
                <directory>${project.basedir}/wrapper/bin</directory>
                <outputDirectory>/bin</outputDirectory>
                <fileMode>755</fileMode>
                <includes>
                    <include>wrapper</include>
                    <include>service.sh</include>
                </includes>
            </fileSet>
            <fileSet>
                <directory>${project.basedir}/wrapper/lib</directory>
                <outputDirectory>/lib</outputDirectory>
                <includes>
                    <include>wrapper.jar</include>
                    <include>libwrapper.so</include>
                </includes>
            </fileSet>
        </fileSets>
    </assembly>
    

    简单标签释义:

    <id>deploy</id>
    

    该标签内容首先不能为空,名称可任意定义,原则上就使用“deploy”,在 maven 编译打包后,其编译的包名会有“-deploy”的命名追加。

    <formats>
        <format>zip</format>
    </formats>
    

    该标签内容指定模块编译后的文件格式。原则上要求使用“zip”,在 maven 编译打包后,其编译的包会压缩成.zip 文件。

    <includeBaseDirectory>false</includeBaseDirectory>
    

    该处理是根据运维自动化部署的实际需要,必须设定该标签为“false”,在 maven 编译打包后,将不包含根级目录

  • 相关阅读:
    python高级编程
    django笔记
    sublime ide
    python3 django mysql
    python win
    linux时区设置
    在实际应用中如何实现切圆角的功能
    display和visiblity在应用中使用哪个好
    看懂UML类图和时序图
    解决Xcode7.2真机调试出现:The account “” has no team with ID “”
  • 原文地址:https://www.cnblogs.com/hailongchen/p/9765588.html
Copyright © 2011-2022 走看看