使用maven将版本号输出到文本文件

发布于 2024-09-15 03:05:01 字数 302 浏览 9 评论 0 原文

我想生成一个 zip 文件,该文件将使用 Maven 更新应用程序。该 zip 将托管在服务器上,我使用程序集插件来生成 zip。不过,我希望 maven 自动生成一个文本文件,将当前版本号存储在 zip 之外。这怎么可能?

编辑: 我使用 Maven 程序集插件和两个描述符成功地创建了两个自定义程序集。其中一个目标是单一目录,它只是根据过滤创建一个包含更新的 version.txt 的文件夹。然后,另一个具有单一目标的文件实际上会打包 zip 文件。这似乎非常不优雅,我想它不会使用整个更新的文件夹正确更新 Maven 存储库。如果有更好的方法来做到这一点,请告诉我。

I want to generate a zip file that will update an application with maven. The zip will be hosted on a server and I am using the assembly plugin to generate the zip. However I would like maven to automatically generate a text file that stores the current version number outside the zip. How is this possible?

EDIT:
I successfully did it using the maven Assembly Plugin and two descriptors to create two custom assemblies. One has a directory-single goal and it just creates a folder with the updated version.txt based on filtering. Then another one with a single goal actually packages the zip file. This seems to be very inelegant and I guess it will not properly update the maven repo with the whole updated folder. If there is a better way to do this, please let me know.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(14

惜醉颜 2024-09-22 03:05:01

当然。在 src/main/resources 中的某个位置创建一个文本文件,将其命名为 version.txt (或其他名称)

文件内容:

${project.version}

现在在 pom.xml 中的 build 元素内,放置此块:

<build>
  <resources>
    <resource>
      <directory>src/main/resources</directory>
      <filtering>true</filtering>
      <includes>
        <include>**/version.txt</include>
      </includes>
    </resource>
    <resource>
      <directory>src/main/resources</directory>
      <filtering>false</filtering>
      <excludes>
        <exclude>**/version.txt</exclude>
      </excludes>
    </resource>
    ...
  </resources>
</build>

在每次构建之后,该文件(您可以在目标/类中找到)将包含当前版本。

现在,如果您想自动将文件移动到其他位置,您可能需要通过 maven-antrun-plugin.

像这样的事情:

  <build>
    ...
    <plugins>
      <plugin>
        <artifactId>maven-antrun-plugin</artifactId>
         <version>1.4</version>
         <executions>
          <execution>
            <phase>process-resources</phase>
            <configuration>
               <tasks>
                 <copy file="${project.build.outputDirectory}/version.txt"
                   toFile="..." overwrite="true" />
              </tasks>
            </configuration>
            <goals>
              <goal>run</goal>
            </goals>
          </execution>
        </executions>
      </plugin>
   </plugins>
 </build>

Sure. Create a text file somewhere in src/main/resources, call it version.txt (or whatever)

File content:

${project.version}

now in your pom.xml, inside the build element, put this block:

<build>
  <resources>
    <resource>
      <directory>src/main/resources</directory>
      <filtering>true</filtering>
      <includes>
        <include>**/version.txt</include>
      </includes>
    </resource>
    <resource>
      <directory>src/main/resources</directory>
      <filtering>false</filtering>
      <excludes>
        <exclude>**/version.txt</exclude>
      </excludes>
    </resource>
    ...
  </resources>
</build>

after every build, the file (which you can find in target/classes) will contain the current version.

Now if you want to move the file somewhere else automatically, you are probably going to need to execute an ant task via the maven-antrun-plugin.

Something like this:

  <build>
    ...
    <plugins>
      <plugin>
        <artifactId>maven-antrun-plugin</artifactId>
         <version>1.4</version>
         <executions>
          <execution>
            <phase>process-resources</phase>
            <configuration>
               <tasks>
                 <copy file="${project.build.outputDirectory}/version.txt"
                   toFile="..." overwrite="true" />
              </tasks>
            </configuration>
            <goals>
              <goal>run</goal>
            </goals>
          </execution>
        </executions>
      </plugin>
   </plugins>
 </build>
始终不够爱げ你 2024-09-22 03:05:01

使用标准 META-INF\MANIFEST.MF (然后您可以使用 Java 代码 getClass().getPackage().getImplementationVersion() 获取版本)

对于 .war 使用此配置:

<plugin>
    <artifactId>maven-war-plugin</artifactId>
    <version>2.1</version>
    <configuration>
        <archive>                   
            <manifest>
                <addDefaultImplementationEntries>true</addDefaultImplementationEntries>
                <addDefaultSpecificationEntries>true</addDefaultSpecificationEntries>
            </manifest>
        </archive>
    </configuration>
</plugin>

这将在构建期间添加清单,或者您可以调用 mvn war:manifest

另请参阅如何在运行Tomcat时获取包版本?

Use standard META-INF\MANIFEST.MF (Then you can use Java code getClass().getPackage().getImplementationVersion() to get version)

For .war use this configuration:

<plugin>
    <artifactId>maven-war-plugin</artifactId>
    <version>2.1</version>
    <configuration>
        <archive>                   
            <manifest>
                <addDefaultImplementationEntries>true</addDefaultImplementationEntries>
                <addDefaultSpecificationEntries>true</addDefaultSpecificationEntries>
            </manifest>
        </archive>
    </configuration>
</plugin>

That will add manifest during build, or you can call mvn war:manifest

See also How to get package version at running Tomcat?

云朵有点甜 2024-09-22 03:05:01

您所指的称为 过滤

您需要启用对特定资源的过滤,然后使用 ${project.version} ,它将被替换为构建的一部分

What you are referring to is called filtering

You need to enable filtering on a particular resource, and then use ${project.version} which will be substituted as part of your build

趴在窗边数星星i 2024-09-22 03:05:01

在 Maven 3 中,使用 Sean 的回答 创建您的 version.txt 文件,(我的显示为此处,以及构建日期和活动配置文件):

${project.version}-${profileID}
${buildDate}

将属性 profileID 添加到每个配置文件,例如:

<properties>
    <profileID>profileName</profileID>
</properties>

使用 Maven 复制资源将文件复制到更容易访问的目录,例如 $ {basedir}${basedir}/target

<plugin>
    <groupId>org.apache.maven.plugins</groupId>
    <artifactId>maven-resources-plugin</artifactId>
    <version>3.0.2</version>
    <executions>
        <execution>
            <id>copy-resources</id>
            <phase>validate</phase>
            <goals>
                <goal>copy-resources</goal>
            </goals>
            <configuration>
                <outputDirectory>${basedir}</outputDirectory>
                <resources>
                    <resource>
                        <directory>${basedir}/target/.../[version.txt dir]/version.txt</directory>
                        <includes>
                            <include>version.txt</include>
                        </includes>
                        <filtering>true</filtering>
                    </resource>
                </resources>
            </configuration>
        </execution>
    </executions>
</plugin>

输出如下所示:

1.2.3-profileName
yymmdd_hhmm

in Maven 3, Use Sean's answer to create your version.txt file, (mine is shown here, along with build date and active profile):

${project.version}-${profileID}
${buildDate}

adding property profileID to each of the profiles, e.g.:

<properties>
    <profileID>profileName</profileID>
</properties>

Use Maven copy-resources to copy the file to an easier to reach directory such as ${basedir} or ${basedir}/target:

<plugin>
    <groupId>org.apache.maven.plugins</groupId>
    <artifactId>maven-resources-plugin</artifactId>
    <version>3.0.2</version>
    <executions>
        <execution>
            <id>copy-resources</id>
            <phase>validate</phase>
            <goals>
                <goal>copy-resources</goal>
            </goals>
            <configuration>
                <outputDirectory>${basedir}</outputDirectory>
                <resources>
                    <resource>
                        <directory>${basedir}/target/.../[version.txt dir]/version.txt</directory>
                        <includes>
                            <include>version.txt</include>
                        </includes>
                        <filtering>true</filtering>
                    </resource>
                </resources>
            </configuration>
        </execution>
    </executions>
</plugin>

output looks like this:

1.2.3-profileName
yymmdd_hhmm
瞳孔里扚悲伤 2024-09-22 03:05:01

对于 Spring Boot 应用程序,请遵循上面接受的答案,但替换

${project.version}

@project.version@

这里是文档的链接 https://github.com/spring-projects/spring-boot/wiki/Spring-Boot-1.3-Release-Notes#maven-resources-filtering< /a>

For a Spring Boot application, follow the accepted answer from above however substituting

${project.version}

with

@project.version@

Here's the link to the documentation https://github.com/spring-projects/spring-boot/wiki/Spring-Boot-1.3-Release-Notes#maven-resources-filtering

一杆小烟枪 2024-09-22 03:05:01

您还可以使用 Groovy 脚本来生成版本信息文件。我更喜欢这种方法,因为您不必排除程序集插件描述符中的内容。您还可以使用此方法选择性地包含仅在从 Jenkins/Hudson 构建时可用的内容(例如检查 oug BUILD_ID 等...)。

因此,您将在 pom.xml 中有一个文件生成 groovy 脚本,如下所示:

  <plugin>
    <groupId>org.codehaus.mojo.groovy</groupId>
    <artifactId>groovy-maven-plugin</artifactId>
    <version>1.0-beta-3</version>
    <executions>
      <execution>
        <phase>test</phase>
        <goals>
          <goal>execute</goal>
        </goals>
        <configuration>
          <source>
        <![CDATA[
        println("==== Creating version.txt ====");
        File mainDir = new File("src/main");
        if(mainDir.exists() && !mainDir.isDirectory()) {
            println("Main dir does not exist, wont create version.txt!");
            return;
        }
        File confDir = new File("src/main/conf");
        if(confDir.exists() && !confDir.isDirectory()) {
            println("Conf dir is not a directory, wont create version.txt!");
            return;
        }
        if(!confDir.exists()) {
            confDir.mkdir();
        }
        File versionFile = new File("src/main/conf/version.txt");
        if(versionFile.exists() && versionFile.isDirectory()) {
            println("Version file exists and is directory! Wont overwrite");
            return;
        }
        if(versionFile.exists() && !versionFile.isDirectory()) {
            println("Version file already exists, overwriting!");
        }
        println("Creating Version File");
        BufferedWriter writer = new BufferedWriter(new FileWriter(versionFile));

        writer.write("groupId = ${project.groupId}");
        writer.newLine();
        writer.write("artifactId = ${project.artifactId}");
        writer.newLine();
        writer.write("version = ${project.version}");
        writer.newLine();
        writer.write("timestamp = ${maven.build.timestamp}");

        String buildTag = "";
        String buildNumber = "";
        String buildId = "";
        try {
            buildTag = "${BUILD_TAG}";
            buildNumber = "${BUILD_NUMBER}";
            buildId = "${BUILD_ID}";

            writer.write("BUILD_TAG = " + buildTag + "\n");
            writer.write("BUILD_NUMBER = " + buildNumber + "\n");
            writer.write("BUILD_ID = " + buildId + "\n");

        } catch (Exception e) {
            println("============= Could not find BUILD_TAG probably this is not a Jenkins/Hudson build ===========");
        }

        writer.close();
        ]]>
          </source>
        </configuration>
      </execution>
    </executions>
  </plugin>

然后 pom.xml 中的程序集插件将如下所示:

  <plugin>
    <artifactId>maven-assembly-plugin</artifactId>
    <version>2.2.1</version>
    <!-- Produce the all-dependencies-included jar for java classloaders -->
    <executions>
      <execution>
        <id>all</id>
        <phase>package</phase>
        <goals>
          <goal>single</goal>
        </goals>
        <configuration>
          <finalName>${project.artifactId}</finalName>
          <descriptors>
            <descriptor>dist-all.xml</descriptor>
          </descriptors>
        </configuration>
      </execution>
    </executions>
  </plugin>

最后,您的程序集描述符 dist-all.xml 将如下所示:

<?xml version="1.0" encoding="UTF-8"?>
<assembly>
  <id>all</id>
  <formats>
    <format>dir</format>
    <format>zip</format>
  </formats>
  <includeBaseDirectory>false</includeBaseDirectory>
  <fileSets>
    <fileSet>
      <directory>target</directory>
      <outputDirectory></outputDirectory>
      <includes>
        <include>*.jar</include>
      </includes>
    </fileSet>
    <fileSet>
      <directory>src/main/conf</directory>
      <outputDirectory></outputDirectory>
      <includes>
        <include>**</include>
      </includes>
    </fileSet>
  </fileSets>
</assembly>

You could also use a Groovy script to produce a version info file. I like this method more because you don't have to exclude stuff in the assembly-plugin's descriptor. You can also use this method to optionally include stuff only available if you are building from Jenkins/Hudson (e.g. check oug BUILD_ID etc...).

So you would have a file-generating groovy script in pom.xml like this:

  <plugin>
    <groupId>org.codehaus.mojo.groovy</groupId>
    <artifactId>groovy-maven-plugin</artifactId>
    <version>1.0-beta-3</version>
    <executions>
      <execution>
        <phase>test</phase>
        <goals>
          <goal>execute</goal>
        </goals>
        <configuration>
          <source>
        <![CDATA[
        println("==== Creating version.txt ====");
        File mainDir = new File("src/main");
        if(mainDir.exists() && !mainDir.isDirectory()) {
            println("Main dir does not exist, wont create version.txt!");
            return;
        }
        File confDir = new File("src/main/conf");
        if(confDir.exists() && !confDir.isDirectory()) {
            println("Conf dir is not a directory, wont create version.txt!");
            return;
        }
        if(!confDir.exists()) {
            confDir.mkdir();
        }
        File versionFile = new File("src/main/conf/version.txt");
        if(versionFile.exists() && versionFile.isDirectory()) {
            println("Version file exists and is directory! Wont overwrite");
            return;
        }
        if(versionFile.exists() && !versionFile.isDirectory()) {
            println("Version file already exists, overwriting!");
        }
        println("Creating Version File");
        BufferedWriter writer = new BufferedWriter(new FileWriter(versionFile));

        writer.write("groupId = ${project.groupId}");
        writer.newLine();
        writer.write("artifactId = ${project.artifactId}");
        writer.newLine();
        writer.write("version = ${project.version}");
        writer.newLine();
        writer.write("timestamp = ${maven.build.timestamp}");

        String buildTag = "";
        String buildNumber = "";
        String buildId = "";
        try {
            buildTag = "${BUILD_TAG}";
            buildNumber = "${BUILD_NUMBER}";
            buildId = "${BUILD_ID}";

            writer.write("BUILD_TAG = " + buildTag + "\n");
            writer.write("BUILD_NUMBER = " + buildNumber + "\n");
            writer.write("BUILD_ID = " + buildId + "\n");

        } catch (Exception e) {
            println("============= Could not find BUILD_TAG probably this is not a Jenkins/Hudson build ===========");
        }

        writer.close();
        ]]>
          </source>
        </configuration>
      </execution>
    </executions>
  </plugin>

And then your assembly plugin plugin in pom.xml that would look like this:

  <plugin>
    <artifactId>maven-assembly-plugin</artifactId>
    <version>2.2.1</version>
    <!-- Produce the all-dependencies-included jar for java classloaders -->
    <executions>
      <execution>
        <id>all</id>
        <phase>package</phase>
        <goals>
          <goal>single</goal>
        </goals>
        <configuration>
          <finalName>${project.artifactId}</finalName>
          <descriptors>
            <descriptor>dist-all.xml</descriptor>
          </descriptors>
        </configuration>
      </execution>
    </executions>
  </plugin>

And finally your assembly descriptor dist-all.xml would look like this:

<?xml version="1.0" encoding="UTF-8"?>
<assembly>
  <id>all</id>
  <formats>
    <format>dir</format>
    <format>zip</format>
  </formats>
  <includeBaseDirectory>false</includeBaseDirectory>
  <fileSets>
    <fileSet>
      <directory>target</directory>
      <outputDirectory></outputDirectory>
      <includes>
        <include>*.jar</include>
      </includes>
    </fileSet>
    <fileSet>
      <directory>src/main/conf</directory>
      <outputDirectory></outputDirectory>
      <includes>
        <include>**</include>
      </includes>
    </fileSet>
  </fileSets>
</assembly>
∝单色的世界 2024-09-22 03:05:01

我刚刚用蚂蚁任务完成了这个。

<echo file="version.txt">${project.version}</echo>

I just did this with an ant task.

<echo file="version.txt">${project.version}</echo>
萌辣 2024-09-22 03:05:01

只需使用 maven-help-plugin 即可。该版本将位于 target/version.txt (或您正在使用的任何构建目录)

<build>
  <plugins>
     <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-help-plugin</artifactId>
        <version>3.2.0</version>
        <executions>
            <execution>
                <id>generate-version-file</id>
                <phase>prepare-package</phase>
                <goals>
                    <goal>evaluate</goal>
                </goals>
                <configuration>
                    <expression>project.version</expression>
                    <output>${project.build.directory}/version.txt</output>
                </configuration>
            </execution>
        </executions>
    </plugin>

Just use the maven-help-plugin. The version will be in target/version.txt (or whatever build directory you are using)

<build>
  <plugins>
     <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-help-plugin</artifactId>
        <version>3.2.0</version>
        <executions>
            <execution>
                <id>generate-version-file</id>
                <phase>prepare-package</phase>
                <goals>
                    <goal>evaluate</goal>
                </goals>
                <configuration>
                    <expression>project.version</expression>
                    <output>${project.build.directory}/version.txt</output>
                </configuration>
            </execution>
        </executions>
    </plugin>

Source

过度放纵 2024-09-22 03:05:01

我更喜欢 write-properties-file-maven-plugin,因为我不希望所有 maven-project-properties 都在一个文件中:

  <plugin>
    <groupId>com.internetitem</groupId>
    <artifactId>write-properties-file-maven-plugin</artifactId>
    <version>1.0.1</version>
    <executions>
      <execution>
        <id>one</id>
        <phase>compile</phase>
        <goals>
            <goal>write-properties-file</goal>
        </goals>
        <configuration>
          <filename>test.properties</filename>
          <properties>
            <property>
              <name>one</name>
              <value>1</value>
            </property>
            <property>
              <name>artifactId</name>
              <value>My Artifact ID is ${project.artifactId}</value>
            </property>
          </properties>
        </configuration>
      </execution>
    </executions>
  </plugin>

I prefer the write-properties-file-maven-plugin, because I don't want all maven-project-properties in one file:

  <plugin>
    <groupId>com.internetitem</groupId>
    <artifactId>write-properties-file-maven-plugin</artifactId>
    <version>1.0.1</version>
    <executions>
      <execution>
        <id>one</id>
        <phase>compile</phase>
        <goals>
            <goal>write-properties-file</goal>
        </goals>
        <configuration>
          <filename>test.properties</filename>
          <properties>
            <property>
              <name>one</name>
              <value>1</value>
            </property>
            <property>
              <name>artifactId</name>
              <value>My Artifact ID is ${project.artifactId}</value>
            </property>
          </properties>
        </configuration>
      </execution>
    </executions>
  </plugin>
恋竹姑娘 2024-09-22 03:05:01

您可以使用 maven-antrun-plugin 和正则表达式将版本输入到文件中。
PS:version.txt文件内容是任意字符串ex:version。

 ...
    <plugins>
      <plugin>
        <artifactId>maven-antrun-plugin</artifactId>
         <version>1.4</version>
         <executions>
          <execution>
            <phase>process-resources</phase>
            <goals>
             <goal>run</goal>
            </goals>
            <configuration>
               <target>
                 <replaceregexp file="resources/version.txt" match=".*" replace="${project.version}" byline="true" />
              </target>
            </configuration>
          </execution>
        </executions>
      </plugin>
   </plugins>

you can use the maven-antrun-plugin and regex expressions to input the version into the file.
PS: version.txt file content is any string ex:version.

 ...
    <plugins>
      <plugin>
        <artifactId>maven-antrun-plugin</artifactId>
         <version>1.4</version>
         <executions>
          <execution>
            <phase>process-resources</phase>
            <goals>
             <goal>run</goal>
            </goals>
            <configuration>
               <target>
                 <replaceregexp file="resources/version.txt" match=".*" replace="${project.version}" byline="true" />
              </target>
            </configuration>
          </execution>
        </executions>
      </plugin>
   </plugins>
计㈡愣 2024-09-22 03:05:01

一种可能性是使用 maven-properties-plugin 将所有项目属性存储到构建的 .jar 中。
然后您可以使用标准(尽管不太实用)读取这些属性 Java 属性 API

        <!-- Build properties to a file -->
        <plugin>
            <groupId>org.codehaus.mojo</groupId>
            <artifactId>properties-maven-plugin</artifactId>
            <version>1.0.0</version>
            <executions>
                <execution>
                    <phase>generate-resources</phase>
                    <goals> <goal>write-project-properties</goal> </goals>
                    <configuration>
                        <outputFile> ${project.build.outputDirectory}/build.properties </outputFile>
                    </configuration>
                </execution>
            </executions>
        </plugin>

请小心使用此方法,因为它可能会泄漏不应该最终发布的属性(也来自 settings.xml)。

One possibility is to store all project properties to the built .jar using maven-properties-plugin.
Then you can read these properties using standard (though not too practical) Java Properties API.

        <!-- Build properties to a file -->
        <plugin>
            <groupId>org.codehaus.mojo</groupId>
            <artifactId>properties-maven-plugin</artifactId>
            <version>1.0.0</version>
            <executions>
                <execution>
                    <phase>generate-resources</phase>
                    <goals> <goal>write-project-properties</goal> </goals>
                    <configuration>
                        <outputFile> ${project.build.outputDirectory}/build.properties </outputFile>
                    </configuration>
                </execution>
            </executions>
        </plugin>

Be careful with this approach as it may leak properties that are not supposed to end up published, also from settings.xml.

一枫情书 2024-09-22 03:05:01

在 pom.xml 中添加以下插件对我有用。这只是上述答案的组合:-

<project>
  [...]
  <build>
    <plugins>
      <plugin>
        <artifactId>maven-antrun-plugin</artifactId>
        <version>3.0.0</version>
        <executions>
          <execution>
            <phase>package</phase>
            <configuration>
              <target><echo file="version.txt">${project.version}</echo> </target>
            </configuration>
            <goals>
              <goal>run</goal>
            </goals>
          </execution>
        </executions>
      </plugin>
    </plugins>
  </build>
  [...]

Adding below plugin in pom.xml worked for me. This is a combination of above answers only:-

<project>
  [...]
  <build>
    <plugins>
      <plugin>
        <artifactId>maven-antrun-plugin</artifactId>
        <version>3.0.0</version>
        <executions>
          <execution>
            <phase>package</phase>
            <configuration>
              <target><echo file="version.txt">${project.version}</echo> </target>
            </configuration>
            <goals>
              <goal>run</goal>
            </goals>
          </execution>
        </executions>
      </plugin>
    </plugins>
  </build>
  [...]
东京女 2024-09-22 03:05:01

要添加到 Sean 的答案中,您可以使用资源中的 targetpath 参数将版本文件移动到 jar 中的文件夹位置。以下代码在 jar 中创建一个名为“resources”的文件夹,并在该文件夹中找到文本文件 (version.number)。

<resource>
    <directory>resources</directory>
    <targetPath>resources</targetPath>
    <filtering>true</filtering>
    <includes>
        <include>version.number</include>
    </includes>
</resource>
<resource>
    <directory>resources</directory>
    <filtering>false</filtering>
    <excludes>
        <exclude>version.number</exclude>
    </excludes>
</resource>

To add to Sean's answer, you can move the version file to a folder location within the jar by using the targetpath parameter within resource. The following code creates a folder called 'resources' within the jar and the text file (version.number) is found in that folder.

<resource>
    <directory>resources</directory>
    <targetPath>resources</targetPath>
    <filtering>true</filtering>
    <includes>
        <include>version.number</include>
    </includes>
</resource>
<resource>
    <directory>resources</directory>
    <filtering>false</filtering>
    <excludes>
        <exclude>version.number</exclude>
    </excludes>
</resource>
音盲 2024-09-22 03:05:01

在 /src/version.txt 中创建包含以下内容的 version.txt

Build version: ${project.version}

使用程序集插件并在 dist.xml 中添加带有filtering=true的步骤

<files>
    <file>
        <source>${basedir}/src/version.txt</source>
        <outputDirectory>${root.dist.folder}</outputDirectory>
        <filtered>true</filtered>
   </file>
</files>

Create version.txt with following content in /src/version.txt

Build version: ${project.version}

Use assembly plugin and add step in dist.xml with filtering=true

<files>
    <file>
        <source>${basedir}/src/version.txt</source>
        <outputDirectory>${root.dist.folder}</outputDirectory>
        <filtered>true</filtered>
   </file>
</files>
~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文