</target>
<target name="build-site" depends="init,prepare">
<property name="swingjsdir" value="swingjs"/>
- <property name="eclipse-inst" value="../../eclipse-js/"/>
+ <property name="eclipse-inst" value="/home/bamboo/buildtools/eclipse/eclipse-js"/>
<property name="eclipse-exec" value="${eclipse-inst}/eclipse"/>
<property name="site" value="site"/>
<!-- where the eclipse js workspace has been initialised -->
<property name="eclipse-workrepo" value="/home/bamboo/buildtools/eclipse/eclipse-js-workspace/jalview-js"/>
<!-- update transpiler -->
- <copy file="${swingjsdir}/net.sf.j2s.core.jar" todir="${eclipse-inst}/dropins"/>
+ <copy file="${swingjsdir}/net.sf.j2s.core.jar" todir="${eclipse-inst}/dropins" overwrite="true" failonerror="true"/>
<!-- update the git repo linked to the eclipse workspace -->
<exec executable="/usr/bin/git" outputproperty="git.commit" failifexecutionfails="true">
<arg value="rev-parse" />
<arg value="--short" />
<arg value="HEAD" />
</exec>
- <!-- and checkout the same commit in the workspace project -->
+ <!-- update and checkout the same commit in the workspace project -->
+ <exec executable="/usr/bin/git" failifexecutionfails="true" dir="${eclipse-workrepo}">
+ <arg value="pull" />
+ </exec>
<exec executable="/usr/bin/git" failifexecutionfails="true" dir="${eclipse-workrepo}">
<arg value="checkout" />
<arg value="${git.commit}" />
</exec>
-
- <copyfile src=".classpath.js" dest="${eclipse-workrepo}/.classpath"/>
+ <!-- custom classpath for .js builds -->
+ <copy file=".classpath.js" tofile="${eclipse-workrepo}/.classpath" overwrite="true"/>
<!-- execute the eclipse build - the build may fail but valid javascript may still be produced, so we ignore return codes -->
<exec executable="${eclipse-exec}" failonerror="no">
<!-- and reset the .classpath -->
<exec executable="/usr/bin/git" failifexecutionfails="true" dir="${eclipse-workrepo}">
<arg value="checkout" />
- <arg value="${git.commit} .classpath" />
+ <arg value="${git.commit}"/>
+ <arg value="--"/>
+ <arg value=".classpath" />
</exec>
<!-- finally copy artefacts from eclipse project checkout to the build site -->
- <copydir src="${eclipse-workrepo}/site" dest="${site}"/>
+ <copy todir="${site}">
+ <fileset dir="${eclipse-workrepo}/site"/>
+ </copy>
<property name="swingjs.zip" value="${swingjsdir}/SwingJS-site.zip" />
<unzip src="${swingjs.zip}" dest="${site}/" overwrite="true"/>
</fileset>
</copy>
+ <!-- copy test files into place in site -->
<copy todir="${site}/examples">
<fileset dir="examples">
<include name="*.*"/>
</fileset>
</copy>
<!-- closure compile -->
- <!-- copy test files into place in site -->
+ <!-- tarball -->
+ <tar compression="gzip" destfile="site.tar.gz">
+ <tarfileset dir="site"/>
+ </tar>
</target>
</project>