You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@turbine.apache.org by jv...@apache.org on 2002/02/20 22:37:40 UTC

cvs commit: jakarta-turbine-maven/src/templates/build build-docs.xml build-test.xml README.txt build.xml default.properties BUILDING.txt

jvanzyl     02/02/20 13:37:40

  Modified:    src/templates/build README.txt build.xml default.properties
  Added:       src/templates/build build-docs.xml build-test.xml
  Removed:     src/templates/build BUILDING.txt
  Log:
  - making the template for the build system, going to try and make a little
    bootstrap mechanism so maven can use itself to build.
  
  Revision  Changes    Path
  1.2       +7 -33     jakarta-turbine-maven/src/templates/build/README.txt
  
  Index: README.txt
  ===================================================================
  RCS file: /home/cvs/jakarta-turbine-maven/src/templates/build/README.txt,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- README.txt	19 Feb 2002 18:10:13 -0000	1.1
  +++ README.txt	20 Feb 2002 21:37:40 -0000	1.2
  @@ -1,33 +1,7 @@
  ---------------------------------------------------------------------------
  -$Id: README.txt,v 1.1 2002/02/19 18:10:13 jvanzyl Exp $
  -Turbine Top Level README
  ---------------------------------------------------------------------------
  -
  -
  -Welcome to Turbine.  For more information about Turbine, please look
  -at the HTML documentation in the docs/ directory.
  -
  -Here is a description of what each of the top level directories
  -contains.  Please consult the documentation in each of the lower level
  -directories for information that is specific to their contents.
  -
  -bin/        This is a temporary directory for building the project.
  -build/      This is where the build scripts live.
  -conf/       This is where the sample configurations live.
  -docs/       This is where the documentation and database schemas live.
  -            All of the files in this directory are mirrored onto
  -            the live website.
  -lib/        This is where the additional libraries and .jar
  -            files reside.
  -src/        This is where all of the source code to Turbine lives.
  -
  -In order to get started with Turbine, you must build it first.  Please
  -refer to BUILDING.txt for details on building Turbine.  For general
  -overview of Turbine and more details on how to use the system, please
  -refer to the documentation in the xdocs/ directory, or at
  -<http://jakarta.apache.org/turbine/>.
  -
  -Thanks,
  -
  -
  --The Turbine Team
  +------------------------------------------------------------------------
  +B U I L D I N G
  +------------------------------------------------------------------------
  +
  +------------------------------------------------------------------------
  +Q U I C K  S T A R T
  +------------------------------------------------------------------------
  
  
  
  1.3       +2 -2      jakarta-turbine-maven/src/templates/build/build.xml
  
  Index: build.xml
  ===================================================================
  RCS file: /home/cvs/jakarta-turbine-maven/src/templates/build/build.xml,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- build.xml	20 Feb 2002 08:11:14 -0000	1.2
  +++ build.xml	20 Feb 2002 21:37:40 -0000	1.3
  @@ -1,8 +1,8 @@
   <?xml version="1.0"?>
   
  -<!-- Build file for Turbine -->
  +<!-- Build file for ${name} -->
   
  -<project name="Turbine" default="jar" basedir=".">
  +<project name="${name}" default="jar" basedir=".">
   
     <!-- Give user a chance to override without editing this file
          (and without typing -D each time they invoke a target) -->
  
  
  
  1.2       +7 -22     jakarta-turbine-maven/src/templates/build/default.properties
  
  Index: default.properties
  ===================================================================
  RCS file: /home/cvs/jakarta-turbine-maven/src/templates/build/default.properties,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- default.properties	19 Feb 2002 18:10:13 -0000	1.1
  +++ default.properties	20 Feb 2002 21:37:40 -0000	1.2
  @@ -1,35 +1,20 @@
   # -------------------------------------------------------------------
   # D E F A U L T  P R O P E R T I E S
   # -------------------------------------------------------------------
  -# These properties are used by the Turbine build, you may override
  -# any of these default values by placing property values in
  -# your ${user.home}/build.properties file.
  -# -------------------------------------------------------------------
   
  -name = Turbine
  -version = 3.0-dev
  -project = turbine
  -organization = Apache Software Foundation
  -inception.year = 1999
  -package = org.apache.turbine
  +name = ${name}
  +version = ${version}
  +project = ${project}
  +organization = ${organization}
  +inception.year = ${inception.year}
  +package = ${package}
   compile.debug = on
   compile.optimize = off
   compile.deprecation = off
   
   # -------------------------------------------------------------------
  -# I M M U T A B L E (possibly maybe :-))
  +# I M M U T A B L E
   # -------------------------------------------------------------------
  -
  -project.defs = ${basedir}/project
  -deps = ${project.defs}/deps.list
  -jar.resources = ${project.defs}/jar.resources
  -src.set = ${project.defs}/src.set
  -src.aspect.set = ${project.defs}/src.aspect.set
  -runtime.test.set = ${project.defs}/runtime-test.resources
  -test.src.set = ${project.defs}/test.src.set
  -unit.test.set = ${project.defs}/unit.test.set
  -rt.test.set = ${project.defs}/rt.test.set
  -rttest.dir = ${src.dir}/rttest
   
   src.dir = ${basedir}/src
   conf.dir = ${basedir}/conf
  
  
  
  1.1                  jakarta-turbine-maven/src/templates/build/build-docs.xml
  
  Index: build-docs.xml
  ===================================================================
  <?xml version="1.0"?>
  
  <project name="Maven" default="docs" basedir=".">
  
    <!-- Allow any user specific values to override the defaults -->
    <property file="${user.home}/build.properties" />
    <!-- Allow user defaults for this project -->
    <property file="build.properties" />
    <!-- Set default values for the build -->
    <property file="default.properties" />
  
    <!-- Construct compile classpath -->
    <path id="classpath">
      <pathelement location="${dom4j.jar}"/>
      <pathelement location="${velocity.jar}"/>
      <pathelement location="${dvsl.jar}" />
      <pathelement location="${commons-collections.jar}" />
      <pathelement location="${log4j.jar}" />
    </path>
  
    <target
      name="docs"
      depends="docs:index, docs:mail-lists, docs:developer-list,docs:dependencies"
      description="o Generate html project documentation xdoc sources">
    </target>
  
    <target
      name="docs:index"
      description="o Generates front page">
  
      <taskdef 
        name="dvsl" 
        classname="org.apache.tools.dvsl.DVSLTask">
        
        <classpath>
          <path refid="classpath"/>
        </classpath>
      </taskdef>
  
      <!-- Make sure the target directory -->
      <mkdir dir="${docs.dest}"/>
  
        <dvsl
          basedir="."
          destdir="${docs.dest}/"
          extension=".html"
          style="${docs.src}/stylesheets/index.dvsl"
          in="project-maven.xml"
          out="${docs.dest}/index.html"
        />
    </target>
  
     <target
      name="docs:mail-lists"
      description="o Generate html project documentation xdoc sources">
  
      <taskdef name="dvsl" classname="org.apache.tools.dvsl.DVSLTask">
        <classpath>
          <path refid="classpath"/>
        </classpath>
      </taskdef>
  
      <!-- Make sure the target directory -->
      <mkdir dir="${docs.dest}"/>
  
        <dvsl
          basedir="."
          destdir="${docs.dest}/"
          extension=".html"
          style="${docs.src}/stylesheets/mail-lists.dvsl"
          in="project-maven.xml"
          out="${docs.dest}/mail-lists.html"
        />
    </target>
  
      <target
      name="docs:developer-list"
      description="o Generate html project documentation xdoc sources">
  
      <taskdef name="dvsl" classname="org.apache.tools.dvsl.DVSLTask">
        <classpath>
          <path refid="classpath"/>
        </classpath>
      </taskdef>
  
      <!-- Make sure the target directory -->
      <mkdir dir="${docs.dest}"/>
  
        <dvsl
          basedir="."
          destdir="${docs.dest}/"
          extension=".html"
          style="${docs.src}/stylesheets/developer-list.dvsl"
          in="project-maven.xml"
          out="${docs.dest}/developer-list.html"
        />
    </target>
  
      <target
      name="docs:dependencies"
      description="o Generate html project documentation xdoc sources">
  
      <taskdef name="dvsl" classname="org.apache.tools.dvsl.DVSLTask">
        <classpath>
          <path refid="classpath"/>
        </classpath>
      </taskdef>
  
      <!-- Make sure the target directory -->
      <mkdir dir="${docs.dest}"/>
  
        <dvsl
          basedir="."
          destdir="${docs.dest}/"
          extension=".html"
          style="${docs.src}/stylesheets/dependencies.dvsl"
          in="project-maven.xml"
          out="${docs.dest}/dependencies.html"
        />
    </target>
  
    <target 
      name="deploy-site" 
      depends="javadocs,docs">
      
      <!-- This needs to taken from the project properties -->
      <property name="homepage" value="/www/jakarta.apache.org/turbine/maven/"/>
  
      <tar tarfile="${project}-site.tar" basedir="${docs.dest}"/>
      <gzip zipfile="${project}-site.tar.gz" src="${project}-site.tar"/>
      <delete file="${project}-site.tar"/>
  
      <exec dir="." executable="scp">
        <arg value="${project}-site.tar.gz"/>
        <arg value="jakarta.apache.org:${homepage}"/>
      </exec>
  
      <exec dir="." executable="ssh">
        <arg line="jakarta.apache.org 'cd ${homepage};gunzip ${project}-site.tar.gz;tar xvf ${project}-site.tar;rm ${project}-site.tar'"/>
      </exec>
  
    </target>
  
    <!-- ================================================================== -->
    <!-- J A V A D O C S                                                    -->
    <!-- ================================================================== -->
  
    <target
      name="javadocs"
      description="o Generates the Javadoc API documentation">
  
      <mkdir dir="${javadoc.destdir}"/>
  
      <!-- Get the year to display in the Javadocs -->
      <tstamp>
        <format property="year" pattern="${inception.year}-yyyy"/>
      </tstamp>
   
      <property 
        name="copyright" 
        value="Copyright &amp;copy; ${year} ${organization}. All Rights Reserved."
      />
      
      <javadoc
        sourcepath="${src.dir}/java"
        packagenames="${package}.*"
        destdir="${javadoc.destdir}"
        author="${author}"
        private="${javadoc.private}"
        version="${javadoc.version}"
        use="${javadoc.use}"
        windowtitle="${javadoc.windowtitle}"
        doctitle="${javadoc.doctitle}"
        bottom="${copyright}">
        <classpath refid="classpath"/>
      </javadoc>
  
    </target>
  
  </project>
  
  
  
  1.1                  jakarta-turbine-maven/src/templates/build/build-test.xml
  
  Index: build-test.xml
  ===================================================================
  <?xml version="1.0"?>
  
  <project name="${name}" default="test" basedir=".">
  
    <!-- Allow any user specific values to override the defaults -->
    <property file="${user.home}/build.properties" />
    <!-- Allow user defaults for this project -->
    <property file="build.properties" />
    <!-- Set default values for the build -->
    <property file="default.properties" />
    <property file="testing.properties"/>
    
    <target
      name="init">
  
      <taskdef
        name="create-path"
        classname="org.apache.maven.CreatePath">
      </taskdef>
      
      <taskdef
        name="create-patternset"
        classname="org.apache.maven.CreatePatternSet">
      </taskdef>
  
      <create-path rid="classpath" descriptor="${deps}" basedir="${lib.repo}"/>
      <create-patternset rid="runtime.test.set" descriptor="${runtime.test.set}"/>
      <create-path rid="test.src.set" descriptor="${test.src.set}"/>
      <create-patternset rid="unit.test.set" descriptor="${unit.test.set}"/>
      <create-patternset rid="rt.test.set" descriptor="${rt.test.set}"/>
    </target>
  
    <!-- ================================================================== -->
    <!-- C O M P I L E  T E S T S                                           -->
    <!-- ================================================================== -->
  
    <target
      name="compile"
      depends="init"
      description="==> compiles the test source code">
      
      <mkdir dir="${build.dest}"/>
      
      <javac 
        destdir="${build.dest}"
        excludes="**/package.html"
        debug="${compile.debug}"
        deprecation="${compile.deprecation}"
        optimize="${compile.optimize}">
        <classpath>
          <path refid="classpath"/>
          <pathelement path="${build.dest}"/>
        </classpath>
        <src>
          <path refid="test.src.set"/>        
        </src>
      </javac>
    </target>
  
    <!-- ================================================================== -->
    <!-- U N I T  T E S T S                                                 -->
    <!-- ================================================================== -->
  
    <target 
      name="test" 
      depends="compile"
      description="runs (junit) unit tests">
      
      <echo>
        Running all JUnit tests
      </echo>
      
      <delete dir="${test.reportsDirectory}"/>
      <mkdir dir="${test.reportsDirectory}"/>
      
      <junit printSummary="yes">
        <formatter type="plain"/>
        <classpath>
          <path refid="classpath"/>
          <pathelement location="${build.dest}"/>
        </classpath>
        <batchtest todir="${test.reportsDirectory}">
          <fileset dir="${build.dest}">
            <patternset refid="unit.test.set"/>
          </fileset>
        </batchtest>
      </junit>
    </target>
  </project>
  
  
  

--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>