简体   繁体   English

执行Eclipse PDE工具>构建站点的脚本

[英]script to execute the eclipse PDE Tools > Build site

i want to write a script to do the Build site of plugin Update site site.xml? 我想编写一个脚本来执行插件更新站点site.xml的构建站点? i could not find a way to do this? 我找不到办法吗? i found very easy to build a plugin feature. 我发现构建插件功能非常容易。 I can automatically creat the ant file build.xml via eclipse but i could not find the same for the update site.xml 我可以通过eclipse自动创建ant文件build.xml,但找不到更新的site.xml文件。

thank you all stefania 谢谢大家stefania

Are you trying to build an Eclipse plugin from Ant? 您是否正在尝试从Ant构建Eclipse插件? You want to use the Ant4Eclipse external add-on for Ant. 您想使用Ant的Ant4Eclipse外部加载项。 It lets you build the run-configurations you've made in Eclipse (right click>run as>...) from your .project file. 它使您可以从.project文件构建在Eclipse中进行的运行配置(右键单击>运行方式> ...)。 You can download it here and there is a tutorial here . 您可以下载它在这里 ,有一个教程在这里

I attempted to do what you're asking at a previous job without using Ant4Eclipse, I don't remember how I got it working, but I do remember it being extremely difficult. 我试图在不使用Ant4Eclipse的情况下完成您上一份工作的要求,我不记得我是如何工作的,但是我确实记得这非常困难。

Edit: you can build an Eclipse update site from the command line, which can be run from Ant. 编辑:您可以从命令行构建一个Eclipse更新站点,该站点可以从Ant运行。 There is some [possibly out of date] documentation here , but I found you a sample from an Apache projects build.xml : 有一些[可能过时]文件在这里 ,但我发现你从一个样本Apache项目的build.xml

  <target name="build-site" depends="init">
    <copy todir="target/eclipse-update-site/web" preservelastmodified="true">
      <fileset dir="web"/>
    </copy>
    <copy todir="target/eclipse-update-site" file="index.html" preservelastmodified="true"/>
    <copy todir="target/eclipse-update-site" file="site.xml" preservelastmodified="true"/>

    <!-- copy all the features to the target -->
    <copy todir="target/eclipse-update-site/features" preservelastmodified="true" >
      <fileset dir="features"/>
    </copy>

    <!-- see http://wiki.eclipse.org/Update_Site_Optimization -->
    <java jar="${eclipse.home}/plugins/org.eclipse.equinox.launcher.jar" fork="true" failonerror="true"
      maxmemory="256m">
      <arg line="-application org.eclipse.update.core.siteOptimizer"/>
      <arg line="-digestBuilder -digestOutputDir=target/eclipse-update-site"/>
      <arg line="-siteXML=target/eclipse-update-site/site.xml"/>
    </java>
  </target>

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM