访问PDE构建后的时间戳 [英] Accessing the timestamp after PDE build

查看:195
本文介绍了访问PDE构建后的时间戳的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我使用Ant来构建我的RCP应用程序。在无头PDE构建行之有效的。然而,对于我的神器一些定制的捆绑,我需要访问PDE使用,同时创造我的插件和特性罐子的时间戳。

Am using ant to build my RCP application. The PDE headless build works well. However for some custom bundling of my artifacts, i need to access the timestamp that PDE uses while creating jars of my plugins and features.

例如:com.test.app.1.0.0.201404091703.jar

Ex: com.test.app.1.0.0.201404091703.jar

我需要从PDE获得的价值201404091703一旦构建成功。这可能吗?

I need to get the value 201404091703 from the PDE once the build is successful. Is this possible?

我试着用forceContextQualifier从build.properties,但这个问题是,在构建之前每次使用ANT是开始,我需要手动更新该值(一些静态值)和重写此全局属性(动态)的不可能的。

I tried with forceContextQualifier from the build.properties, but the problem with this is, everytime before the build starts i need to update this value manually (to some static value) and overriding of this global property (dynamically) using ANT is not possible.

任何建议是AP preciated

Any suggestions is appreciated

推荐答案

您可以指定 -DforceContextQualifier = XXX 作为参数传递给组织。 eclipse.equinox.launcher_xxx 在你的build.xml运行。

You can specify -DforceContextQualifier=xxx as an argument to the org.eclipse.equinox.launcher_xxx run in your build.xml.

更新:

所以,例如:

<buildnumber file="build.number"/>

<tstamp>
  <format property="build.date" pattern="yyyyMMddHHmm" timezone="GMT"/>
</tstamp>

<property name="build.version" value="${build.date}-${build.number}"/>

<java fork="true" jar="${jar.launcher}">
  <arg value="-DforceContextQualifier=${build.version}"/>
  ...

设定的预选赛构建到为yyyymmddhhmm-NUM

Sets the qualifier for a build to YYYYMMDDHHMM-num

这篇关于访问PDE构建后的时间戳的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆