/plugins/ShortcutDisplay/tags/rel_1_0/build.xml

# · XML · 125 lines · 82 code · 20 blank · 23 comment · 0 complexity · a377ac824f89b38e9041bc7aa8a8013f MD5 · raw file

  1. <?xml version="1.0"?>
  2. <!--
  3. This is a build.xml file for building the FTP plugin.
  4. The 'dist' target compiles the plugin and creates the JAR file.
  5. Before running the 'dist' target, you will need to generate the
  6. documentation using one of these two targets:
  7. - 'docs-xalan': Creates documentation using the Xalan XSLT processor
  8. - 'docs-xsltproc': Creates documentation using the xsltproc tool
  9. To use it for building your own plugin, make these changes:
  10. - Change definition of 'jar.name' to the name of your plugin's JAR file
  11. - If necessary, add any dependencies to the 'project.class.path'
  12. definition
  13. - If necessary, change the list of files in the 'dist' targtet
  14. - If necessary, change the 'docs-xalan' and 'docs-xsltproc' targets
  15. accordingly.
  16. -->
  17. <project name="ShortcutDisplay" default="dist" basedir=".">
  18. <property file="build.properties"/>
  19. <property name="jar.name" value="ShortcutDisplay.jar"/>
  20. <property name="src.dir" value="src"/>
  21. <property name="build.dir" value="build"/>
  22. <property name="install.dir" value=".."/>
  23. <property name="docs-proc.target" value="xsltproc" />
  24. <property name="jedit.install.dir" value="../../jEdit" />
  25. <path id="project.class.path">
  26. <pathelement location="${jedit.install.dir}/jedit.jar" />
  27. <pathelement location="."/>
  28. </path>
  29. <target name="init">
  30. <mkdir dir="${build.dir}" />
  31. <delete file="docbook-wrapper.xsl" />
  32. <echo file="docbook-wrapper.xsl" message="&lt;xsl:stylesheet" />
  33. <echo file="docbook-wrapper.xsl" append="true" message=" xmlns:xsl=&quot;http://www.w3.org/1999/XSL/Transform&quot;" />
  34. <echo file="docbook-wrapper.xsl" append="true" message=" version=&quot;1.0&quot;&gt;" />
  35. <echo file="docbook-wrapper.xsl" append="true" message="&lt;xsl:import href=&quot;${docbook.xsl}/html/docbook.xsl&quot;/&gt;" />
  36. <echo file="docbook-wrapper.xsl" append="true" message="&lt;/xsl:stylesheet&gt;" />
  37. </target>
  38. <target name="compile" depends="init">
  39. <javac
  40. srcdir="${src.dir}"
  41. destdir="${build.dir}"
  42. deprecation="on"
  43. includeJavaRuntime="yes"
  44. >
  45. <classpath refid="project.class.path"/>
  46. </javac>
  47. </target>
  48. <target name="dist" depends="compile, docs">
  49. <mkdir dir="${install.dir}"/>
  50. <jar jarfile="${install.dir}/${jar.name}">
  51. <fileset dir="${build.dir}"/>
  52. <fileset dir=".">
  53. <include name="actions.xml"/>
  54. <include name="browser.actions.xml"/>
  55. <include name="services.xml"/>
  56. <include name="*.props"/>
  57. <include name="**/*.html"/>
  58. <include name="**/*.gif"/>
  59. <include name="conf/*.xml"/>
  60. </fileset>
  61. </jar>
  62. </target>
  63. <!-- Generate docs with xsltproc tool from www.xmlsoft.org -->
  64. <target name="docs-xsltproc" depends="init">
  65. <exec executable="xsltproc">
  66. <arg value="--catalogs"/>
  67. <arg value="users-guide.xsl"/>
  68. <arg value="users-guide.xml"/>
  69. </exec>
  70. </target>
  71. <target name="docs" depends="init">
  72. <antcall target="docs-${docs-proc.target}" />
  73. </target>
  74. <!-- Generate docs with Xalan tool from xml.apache.org -->
  75. <target name="docs-xalan" depends="init">
  76. <property name="dtd.location" value="http://www.oasis-open.org/docbook/xml/4.2/docbookx.dtd"/>
  77. <!-- <echoproperties/> -->
  78. <xslt style="users-guide.xsl"
  79. in="users-guide.xml"
  80. out="index.html">
  81. <xmlcatalog>
  82. <dtd publicId="-//OASIS//DTD DocBook XML V4.1.2//EN"
  83. location="${dtd.location}"/>
  84. </xmlcatalog>
  85. </xslt>
  86. </target>
  87. <target name="clean">
  88. <delete dir="${build.dir}"/>
  89. <delete>
  90. <fileset dir="." includes="**/*~" defaultexcludes="no"/>
  91. <fileset dir="." includes="**/*.html" defaultexcludes="no"/>
  92. </delete>
  93. </target>
  94. <!-- Generate tags using 'ctags' program from ctags.sourceforge.net -->
  95. <target name="tags">
  96. <exec executable="ctags">
  97. <arg value="-R" />
  98. <arg path="." />
  99. </exec>
  100. </target>
  101. </project>