You are viewing a plain text version of this content. The canonical link for it is here.
Posted to svn@forrest.apache.org by rg...@apache.org on 2005/04/22 00:11:27 UTC
svn commit: r164136 - /forrest/trunk/plugins/build.xml
Author: rgardler
Date: Thu Apr 21 15:11:26 2005
New Revision: 164136
URL: http://svn.apache.org/viewcvs?rev=164136&view=rev
Log:
revert inadvertantly commited in-progress changes
Modified:
forrest/trunk/plugins/build.xml
Modified: forrest/trunk/plugins/build.xml
URL: http://svn.apache.org/viewcvs/forrest/trunk/plugins/build.xml?rev=164136&r1=164135&r2=164136&view=diff
==============================================================================
--- forrest/trunk/plugins/build.xml (original)
+++ forrest/trunk/plugins/build.xml Thu Apr 21 15:11:26 2005
@@ -17,38 +17,30 @@
-->
<project default="local-deploy" basedir="." name="Forrest_Plugins_build_file">
<property environment="env"/>
- <property name="forrest.version" value="0.7"/>
- <property name="forrest.home" location="${env.FORREST_HOME}"/>
- <property name="forrest.core" location="${env.FORREST_HOME}/main" />
- <property name="forrest.ant.lib.dir" location="${forrest.home}/tools/ant/lib"/>
- <property name="forrest.build.dir" location="${forrest.home}/build"/>
- <property name="forrest.plugins.dir" location="${forrest.home}/plugins"/>
- <property name="forrest.plugins.build.dir" location="${forrest.home}/plugins/build"/>
- <property name="forrest.plugins.dist.dir" location="${forrest.plugins.build.dir}/dist"/>
- <property name="forrest.plugins.template.dir" location="${forrest.plugins.dir}/pluginTemplate"/>
- <property name="forrest.plugins.localDeploy.dir" location="${forrest.build.dir}/plugins"/>
+ <property name="forrest.home" location="${env.FORREST_HOME}"/>
+ <property name="forrest.core" location="${env.FORREST_HOME}/main" />
+ <property name="forrest.ant.lib.dir" location="${forrest.home}/tools/ant/lib"/>
+ <property name="forrest.build.dir" location="${forrest.home}/build"/>
+ <property name="forrest.plugins.dir" location="${forrest.home}/plugins"/>
+
+ <property name="plugins.dir" location="${ant.file.Forrest_Plugins_build_file}/.."/>
+ <property name="plugins.dist-dir" location="build/dist"/>
+ <property name="plugins.localDeploy-dir" location="${forrest.build.dir}/plugins"/>
- <!-- the plugin config (i.e. applies to current plugin) -->
<property name="plugin.src.dir" value="src"/>
- <property name="plugin.java.dir" value="${plugin.src.dir}/java"/>
- <property name="plugin.lib.dir" value="lib"/>
<property name="plugin.resources.dir" value="resources"/>
<property name="plugin.stylesheets.dir" value="${plugin.resources.dir}/stylesheets"/>
+ <property name="plugin.template.dir" value="pluginTemplate"/>
+
<property name="deploy.svn.user" value=""/>
<property name="deploy.svn.password" value=""/>
- <property name="deploy.plugins.svn.url" value="https://svn.apache.org/repos/asf/forrest/site/plugins"/>
- <property name="deploy.plugin.docs.svn.url" value="https://svn.apache.org/repos/asf/forrest/site/${forrest.version}/docs/plugins"/>
- <property name="deploy.plugins.svn-dir" location="${forrest.build.dir}/svn-plugins-deploy"/>
- <property name="deploy.docs.svn-dir" location="${forrest.build.dir}/svn-plugin-docs-deploy"/>
- <property name="deploy.plugins.svn-filestoadd" location="build/svn-plugin.deploy.toadd"/>
- <property name="deploy.docs.svn-filestoadd" location="build/svn-docs.deploy.toadd"/>
- <property name="deploy.plugins.sandbox.dir" location="${deploy.plugins.svn-dir}"/>
- <property name="deploy.docs.sandbox.dir" location="${deploy.docs.svn-dir}"/>
+ <property name="deploy.svn.url" value="https://svn.apache.org/repos/asf/forrest/site/plugins"/>
+ <property name="deploy.svn.svn-dir" location="${forrest.build.dir}/svn-plugins-deploy"/>
+ <property name="deploy.svn.svn-filestoadd" location="build/svn-deploy.toadd"/>
<property name="build.dir" location="build"/>
<property name="build.classes" location="${build.dir}/classes"/>
- <property name="build.docs" location="${build.dir}/site"/>
<taskdef resource="net/sf/antcontrib/antcontrib.properties">
<classpath>
@@ -102,17 +94,17 @@
<path id="classpath">
<fileset dir="${forrest.home}/lib" includes="**/*.jar"/>
- <fileset dir="${plugin.lib.dir}" includes="*.jar"/>
- <fileset dir="${plugin.lib.dir}" includes="*.zip"/>
+ <fileset dir="lib" includes="*.jar"/>
+ <fileset dir="lib" includes="*.zip"/>
</path>
- <available file="${plugin.java.dir}" property="java_exists" type="dir"/>
+ <available file="${java.dir}" property="java_exists" type="dir"/>
</target>
<target name="clean" depends="init">
- <delete dir="${forrest.plugins.localDeploy.dir}/${plugin-name}"/>
- <delete dir="${forrest.plugins.dist.dir}"/>
+ <delete dir="${plugins.localDeploy-dir}/${plugin-name}"/>
+ <delete dir="${plugins.dist-dir}"/>
</target>
@@ -123,19 +115,14 @@
<echo>Locally deploying ${plugin-name}</echo>
- <copy toDir="${forrest.plugins.localDeploy.dir}/${plugin-name}">
- <fileset dir="${forrest.plugins.dir}/${plugin-name}">
- <exclude name="lib/**"/>
+ <copy toDir="${plugins.localDeploy-dir}/${plugin-name}">
+ <fileset dir="${plugins.dir}/${plugin-name}">
<exclude name="build/**"/>
</fileset>
</copy>
- <copy toFile="${forrest.plugins.localDeploy.dir}/lib/${plugin-name}.jar"
+ <copy toFile="${plugins.localDeploy-dir}/lib/${plugin-name}.jar"
file="${build.dir}/${plugin-name}.jar"
failonerror="false"/>
- <copy toDir="${forrest.plugins.localDeploy.dir}/lib"
- failonerror="false">
- <fileset dir="lib"/>
- </copy>
<antcall target="build"/>
</target>
@@ -144,132 +131,65 @@
<target name="deploy-plugins.xml"
description="Deployes the plugins descriptor file (plugins.xml) to the website SVN repository"
- depends="checkout-deployed-plugins">
-
- <copy todir="${deploy.plugins.svn-dir}"
+ depends="checkout-deployed">
+ <copy todir="${deploy.svn.svn-dir}"
overwrite="true"
file="${forrest.plugins.dir}/plugins.xml"/>
-
<!-- check in to SVN -->
- <!--
- =====================================
- ========== FIXME ====================
- =====================================
<svncommit
- target="${deploy.plugins.svn-dir}"
- repositoryurl="${deploy.plugins.svn.url}"
+ target="${deploy.svn.svn-dir}"
+ repositoryurl="${deploy.svn.url}"
commitmessage="Deployment plugins descriptor file (plugins.xml) (deployed by 'deploy-plugins.xml' target of plugin build script)"
/>
- -->
- </target>
-
- <target name="deploy-docs"
- description="Deploy the plugin documentation"
- depends="dist, docs, checkout-deployed-docs, deploy-plugins.xml">
- <echo>Deploying plugin documentation to the web server</echo>
-
- <!-- Copy plugin docs into sandbox -->
- <copy todir="${deploy.docs.sandbox.dir}/${plugin-name}"
- overwrite="true">
- <fileset dir="${build.docs}"/>
- </copy>
-
- <!-- add new files to SVN -->
- <!-- svnadd doesn't work (it doesn't change the working directory properly) -->
- <exec executable="svn" dir="${deploy.docs.svn-dir}" output="${deploy.docs.svn-filestoadd}" failonerror="true">
- <arg value="status"/>
- </exec>
- <!-- the status columns make all lines invalid filenames
- we remove the status columns for the new files so the only valid
- filenames in the list are new files
- -->
- <replace file="${deploy.docs.svn-filestoadd}" token="? " value=""/>
- <replace file="${deploy.docs.svn-filestoadd}" token="M " value=""/>
- <!-- don't fail on error here because
- 1) the targets file might have 'bad' filenames but we should continue
- 2) we would've already failed if the svn executable wasn't found
- -->
- <exec executable="svn" dir="${deploy.plugins.svn-dir}">
- <arg value="add"/>
- <arg value="--targets"/>
- <arg value="${deploy.plugins.svn-filestoadd}"/>
- </exec>
- <!-- check in to SVN -->
- <!--
- =====================================
- ========== FIXME ====================
- =====================================
- <svncommit
- target="${deploy.plugins.svn-dir}"
- repositoryurl="${deploy.plugins.svn.url}"
- commitmessage="Deployment of ${plugin-name} plugin (deployed by 'deploy' target of plugin build script)"
- />
- -->
</target>
<target name="deploy"
description="Deploy the plugin to SVN"
- depends="clean, deploy-plugins.xml, deploy-docs, dist, checkout-deployed-plugins">
+ depends="dist, checkout-deployed, deploy-plugins.xml">
<echo>Deploying ${plugin-name} to the web server</echo>
-
- <!-- copy new plugin files into sandbox -->
- <copy todir="${deploy.plugins.svn-dir}"
+
+ <!-- copy new files into sandbox -->
+ <copy todir="${deploy.svn.svn-dir}"
overwrite="true"
- file="${forrest.plugins.dist.dir}/${plugin-name}.zip"/>
+ file="${plugins.dist-dir}/${plugin-name}.zip"/>
<!-- add new files to SVN -->
<!-- svnadd doesn't work (it doesn't change the working directory properly) -->
- <exec executable="svn" dir="${deploy.plugins.svn-dir}" output="${deploy.plugins.svn-filestoadd}" failonerror="true">
+ <exec executable="svn" dir="${deploy.svn.svn-dir}" output="${deploy.svn.svn-filestoadd}" failonerror="true">
<arg value="status"/>
</exec>
<!-- the status columns make all lines invalid filenames
we remove the status columns for the new files so the only valid
filenames in the list are new files
-->
- <replace file="${deploy.plugins.svn-filestoadd}" token="? " value=""/>
- <replace file="${deploy.plugins.svn-filestoadd}" token="M " value=""/>
+ <replace file="${deploy.svn.svn-filestoadd}" token="? " value=""/>
+ <replace file="${deploy.svn.svn-filestoadd}" token="M " value=""/>
<!-- don't fail on error here because
1) the targets file might have 'bad' filenames but we should continue
2) we would've already failed if the svn executable wasn't found
-->
- <exec executable="svn" dir="${deploy.plugins.svn-dir}">
+ <exec executable="svn" dir="${deploy.svn.svn-dir}">
<arg value="add"/>
<arg value="--targets"/>
- <arg value="${deploy.plugins.svn-filestoadd}"/>
+ <arg value="${deploy.svn.svn-filestoadd}"/>
</exec>
+
<!-- check in to SVN -->
- <!--
- =====================================
- ========== FIXME ====================
- =====================================
<svncommit
- target="${deploy.plugins.svn-dir}"
- repositoryurl="${deploy.plugins.svn.url}"
+ target="${deploy.svn.svn-dir}"
+ repositoryurl="${deploy.svn.url}"
commitmessage="Deployment of ${plugin-name} plugin (deployed by 'deploy' target of plugin build script)"
/>
- -->
- </target>
-
- <target name="checkout-deployed-docs"
- description="Retrieve the currently deployed plugin files">
- <!-- get current plugins directory from SVN -->
- <svncheckout
- repositoryurl="${deploy.plugin.docs.svn.url}"
- username="${deploy.svn.user}"
- password="${deploy.svn.password}"
- destination="${deploy.docs.svn-dir}"
- failonerror="true"
- />
</target>
- <target name="checkout-deployed-plugins"
+ <target name="checkout-deployed"
description="Retrieve the currently deployed plugin files">
<!-- get current plugins directory from SVN -->
<svncheckout
- repositoryurl="${deploy.plugins.svn.url}"
+ repositoryurl="${deploy.svn.url}"
username="${deploy.svn.user}"
password="${deploy.svn.password}"
- destination="${deploy.plugins.svn-dir}"
+ destination="${deploy.svn.svn-dir}"
failonerror="true"
/>
</target>
@@ -281,13 +201,13 @@
</ant>
</target>
- <!-- FIXME: needs to append plugin version number to filename -->
+ <!-- FIXME: needs to append FOrrest version number to filename -->
<target name="dist"
description="Build the distribution archive for all the plugins"
- depends="init">
- <mkdir dir="${forrest.plugins.dist.dir}"/>
- <zip destfile="${forrest.plugins.dist.dir}/${plugin-name}.zip"
- basedir="${forrest.plugins.dir}/${plugin-name}"
+ depends="init, test, docs">
+ <mkdir dir="${plugins.dist-dir}"/>
+ <zip destfile="${plugins.dist-dir}/${plugin-name}.zip"
+ basedir="${plugins.dir}/${plugin-name}"
includes="**"
excludes="**/build/**"/>
</target>
@@ -301,7 +221,7 @@
<mkdir dir="${plugin-name}/${plugin.stylesheets.dir}"/>
<copy todir="${plugin-name}"
filtering="true">
- <fileset dir="${forrest.plugins.template.dir}"/>
+ <fileset dir="${plugin.template.dir}"/>
<filterset>
<filter token="plugin-name" value="${plugin-name}"/>
</filterset>
@@ -319,7 +239,7 @@
<!-- =================================================================== -->
<target name="compile" depends="init" if="java_exists">
<mkdir dir="${build.classes}"/>
- <javac srcdir= "${plugin.java.dir}"
+ <javac srcdir= "${java.dir}"
destdir= "${build.classes}"
debug= "${build.compiler.debug}"
optimize= "${build.compiler.optimize}"
@@ -329,7 +249,7 @@
</javac>
<copy todir="${build.classes}">
- <fileset dir="${plugin.java.dir}">
+ <fileset dir="${java.dir}">
<exclude name="**/*.java"/>
</fileset>
</copy>
Re: svn commit: r164136 - /forrest/trunk/plugins/build.xml
Posted by Ross Gardler <rg...@apache.org>.
David Crossley wrote:
> Ross Gardler wrote:
>
>>>Author: rgardler
>>>Date: Thu Apr 21 15:11:26 2005
>>>New Revision: 164136
>>>
>>>URL: http://svn.apache.org/viewcvs?rev=164136&view=rev
>>>Log:
>>>revert inadvertantly commited in-progress changes
>>>
>>
>>Clearly I managed to do this, but I feel that my way of doing it was
>>very hacky and svn being such a powerful tool I suspect there is a much
>>easier way.
>>
>>How would one go about reverting the version in the repository to a
>>previous version.
>>
>>i.e. what is the equivalent of "svn revert" for the remote repository.
>
>
> I am no svn expert. Can you revert your working copy with
> with 'svn revert -R .' then commit the changes?
> Or perhaps use 'svn merge' to go back to a specific revision.
No, I tried that, but it seems to only want to allow you to commit if
you have the latest revision on your disk. There must be a way, I'll ask
on a more appropriate list and report back when I find the answer.
Ross
Re: svn commit: r164136 - /forrest/trunk/plugins/build.xml
Posted by David Crossley <cr...@apache.org>.
Ross Gardler wrote:
> >Author: rgardler
> >Date: Thu Apr 21 15:11:26 2005
> >New Revision: 164136
> >
> >URL: http://svn.apache.org/viewcvs?rev=164136&view=rev
> >Log:
> >revert inadvertantly commited in-progress changes
> >
>
> Clearly I managed to do this, but I feel that my way of doing it was
> very hacky and svn being such a powerful tool I suspect there is a much
> easier way.
>
> How would one go about reverting the version in the repository to a
> previous version.
>
> i.e. what is the equivalent of "svn revert" for the remote repository.
I am no svn expert. Can you revert your working copy with
with 'svn revert -R .' then commit the changes?
Or perhaps use 'svn merge' to go back to a specific revision.
--David
Re: svn commit: r164136 - /forrest/trunk/plugins/build.xml
Posted by Ross Gardler <rg...@apache.org>.
rgardler@apache.org wrote:
> Author: rgardler
> Date: Thu Apr 21 15:11:26 2005
> New Revision: 164136
>
> URL: http://svn.apache.org/viewcvs?rev=164136&view=rev
> Log:
> revert inadvertantly commited in-progress changes
>
Clearly I managed to do this, but I feel that my way of doing it was
very hacky and svn being such a powerful tool I suspect there is a much
easier way.
How would one go about reverting the version in the repository to a
previous version.
i.e. what is the equivalent of "svn revert" for the remote repository.
Ross