You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@forrest.apache.org by cr...@apache.org on 2002/08/25 05:04:26 UTC
cvs commit: xml-forrest/src/resources/forrest-shbat/bin forrest.sh
crossley 2002/08/24 20:04:26
Modified: . build.build.xml forrest.build.xml
src/resources/forrest-shbat/bin forrest.sh
Log:
Tweaks to the new shbat functionality:
- Users need not have ANT_HOME set, just 'ant' in their PATH - more robust.
- The $FORREST_HOME is set properly (!= PROJECT_HOME).
- Automatically fix permissions on forrest.sh
Submitted by: Jeff Turner <je...@apache.org>
Revision Changes Path
1.5 +3 -0 xml-forrest/build.build.xml
Index: build.build.xml
===================================================================
RCS file: /home/cvs/xml-forrest/build.build.xml,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -r1.4 -r1.5
--- build.build.xml 23 Aug 2002 16:14:24 -0000 1.4
+++ build.build.xml 25 Aug 2002 03:04:26 -0000 1.5
@@ -295,6 +295,9 @@
<copy todir="${dist-shbat.dir}">
<fileset dir="./src/resources/forrest-shbat" />
</copy>
+ <fixcrlf eol="crlf" srcdir="${dist-shbat.dir}/bin" includes="*.bat"/>
+ <fixcrlf eol="lf" srcdir="${dist-shbat.dir}/bin" excludes="*.bat"/>
+ <chmod dir="${dist-shbat.dir}/bin" perm="ugo+rx" excludes="*.bat"/>
<!-- copy the fresh-site.zip to clone from -->
<copy todir="${dist-shbat.dir}" file="${fresh-site.zip}" />
1.5 +3 -2 xml-forrest/forrest.build.xml
Index: forrest.build.xml
===================================================================
RCS file: /home/cvs/xml-forrest/forrest.build.xml,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -r1.4 -r1.5
--- forrest.build.xml 23 Aug 2002 16:14:24 -0000 1.4
+++ forrest.build.xml 25 Aug 2002 03:04:26 -0000 1.5
@@ -14,7 +14,7 @@
<description>
*=======================================================*
- | Forrest ant based site building target-temaplates |
+ | Forrest ant based site building target-templates |
*=======================================================*
by
Marc Portier (mpo@apache.org)
@@ -149,13 +149,14 @@
Relative to project.home there will be a number of default
paths forrest will use to do the requested work.
- To see these (and there use), use the nested property:
+ To see these (and their use), use the nested property:
<property name="forrest.echo" value="true" />
To override these you could do one of:
- write them down in a file ${project.home}/forrest.properties
(using Java Property file syntax)
- set them as nested properties to the <ant> task.
+ - set them from the command-line, eg -Dforrest.echo=true
Targets to call:
[site building targets]
1.3 +5 -3 xml-forrest/src/resources/forrest-shbat/bin/forrest.sh
Index: forrest.sh
===================================================================
RCS file: /home/cvs/xml-forrest/src/resources/forrest-shbat/bin/forrest.sh,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -r1.2 -r1.3
--- forrest.sh 22 Aug 2002 16:07:50 -0000 1.2
+++ forrest.sh 25 Aug 2002 03:04:26 -0000 1.3
@@ -4,18 +4,20 @@
# ----- Test if ant is around ------------------------------------------------
# and bail out if it does not with a message that it is required
-if [ "$ANT_HOME" = "" ] ; then
+if [ ! `which ant` ]; then
echo "You must install Ant (http://jakarta.apache.org/ant)"
- echo "and set ANT_HOME to point at your Ant Installation directory."
+ echo "and add \$ANT_HOME/bin to your PATH variable"
exit 1
fi
# set the current working dir as the PROJECT_HOME variable
PROJECT_HOME=$PWD
+# use the location of this script to infer $FORREST_HOME
+FORREST_HOME=`dirname $0`/..
# set the ant file to use
ANTFILE=$FORREST_HOME/forrest.build.xml
# call ant.
-$ANT_HOME/bin/ant -buildfile $ANTFILE -Dproject.home=$PROJECT_HOME -Dforrest.home=$FORREST_HOME -emacs -logger org.apache.tools.ant.NoBannerLogger $@
+ant -buildfile $ANTFILE -Dproject.home=$PROJECT_HOME -Dforrest.home=$FORREST_HOME -emacs $@