更改产品版本

时间:2017-06-23 06:04:57

标签: tycho

我有一个非常基本的项目设置,没有子模块或任何东西。只是一个没有花哨的 pom.xml

<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">
    <modelVersion>4.0.0</modelVersion>
    <groupId>org.acme.product</groupId>
    <artifactId>org.acme.product</artifactId>
    <version>0.0.9</version>
    <packaging>eclipse-repository</packaging>

    <build>
        <plugins>
            <plugin>
                <groupId>org.eclipse.tycho</groupId>
                <artifactId>tycho-maven-plugin</artifactId>
                <version>0.26.0</version>
                <extensions>true</extensions>
            </plugin>

            <plugin>
                <groupId>org.eclipse.tycho</groupId>
                <artifactId>target-platform-configuration</artifactId>
                <version>0.26.0</version>
                <configuration>
                    <resolver>p2</resolver>
                    <target>
                        <artifact>
                            <groupId>org.acme.product</groupId>
                            <artifactId>org.acme.product</artifactId>
                            <version>${project.version}</version>
                            <classifier>platform</classifier>
                        </artifact>
                    </target>
                    <ignoreTychoRepositories>true</ignoreTychoRepositories>
                    <environments>
                        <environment>
                            <os>win32</os>
                            <ws>win32</ws>
                            <arch>x86</arch>
                        </environment>
                    </environments>
                </configuration>
            </plugin>
        </plugins>
    </build>
</project>

当然,有一个名为 platform.target 的目标平台,其功能为org.eclipse.equinox.executable.feature.group。最后有一个(空的)产品具有相同的ID和版本。

现在我想用Tycho来更新这个版本。我知道,它只有两个文件。仍然。

mvn org.eclipse.tycho:tycho-versions-plugin:set-version -DnewVersion=1.0.0

pom.xml 将会更新,但产品不会更新。插件和功能同样适用,我也无法弄清楚它为什么不能与产品一起使用。

有人可以帮助改变产品的版本吗?

1 个答案:

答案 0 :(得分:0)

检查pom.xml版本和产品版本是否相同。

  

仅当旧版本与eclipse存储库POM中的版本匹配时,版本插件才会更新产品文件中的版本。   版本(故意)与POM版本不同的产品文件不会更新。这与模块相同:与根POM版本不同的模块不会更新。

请参阅此错误report