<?xml version="1.0"?>
<!--
  Licensed to the Apache Software Foundation (ASF) under one or more
  contributor license agreements.  See the NOTICE file distributed with
  this work for additional information regarding copyright ownership.
  The ASF licenses this file to You under the Apache License, Version 2.0
  (the "License"); you may not use this file except in compliance with
  the License.  You may obtain a copy of the License at
  
  http://www.apache.org/licenses/LICENSE-2.0
  
  Unless required by applicable law or agreed to in writing, software
  distributed under the License is distributed on an "AS IS" BASIS,
  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  See the License for the specific language governing permissions and
  limitations under the License.
-->
<!DOCTYPE document PUBLIC "-//APACHE//DTD Documentation V1.3//EN" "http://forrest.apache.org/dtd/document-v13.dtd">
<document><header><title>Project Guidelines</title></header><body>
    <section id="project">
      <title>The xml.apache.org Project Guidelines</title>
      <p>
      This document defines the guidelines of the <em>xml.apache.org</em> 
      project. It includes definitions of the various categories of 
      membership, who is able to vote, how conflicts are resolved by voting, 
      and the procedures to follow for proposing and making changes to the 
      codebase of the Project.
    </p><note>
      Note that our sister project, jakarta.apache.org, is formulating 
      a number of other project-wide guidelines that the xml community may 
      wish to copy or modify.  In Sept-2001 there are also a number of 
      discussions on the general@xml.apache.org and commons-dev@xml.apache.org 
      mailing lists about other cross-project guidelines that we hope will 
      standardize our projects and make developing and using them easier.
      Stay tuned!
    </note><p>
      This is a living document. Changes can be made by the Project 
      Management Committee. 
    </p><ul><li><link href="roles.html">Roles and Responsibilities</link>
        Defines the recognized roles in the project.</li><li><link href="communication.html">
    Communication</link>
        Defines how users and developers communicate.</li><li><link href="decisions.html">Decision Making</link>
        Defines how action items are proposed and voted on.</li><li><link href="source.html">Source Repositories</link>
        Defines how the Project's source code is organized and developed.</li><li><link href="management.html">Project Management</link>
        Defines the roles and responsibilities of the Project Management
        Committee (PMC).</li><li><link href="mission.html">Our Mission / Charter</link>
        A copy of the Charter document for the xml.apache.org Project.</li></ul></section>
        
	<section id="website">
    <title>Website update guidelines</title>
	  <p>
		As XML-oriented projects, so our website is also generated from 
		XML files.  While many similar websites may use servlets or a 
		system like Cocoon to generate their websites on-the-fly 
		from XML documents, we currently checkin source .xml files 
		of the documentation and then generate a static set of .html 
		files for most of this website.
	  </p>
		<p>
		While each subproject's individual areas may be managed separately 
		(by that subproject's committers) the top-level of the website 
		must be managed through the 
		<link href="http://svn.apache.org/repos/asf/xml/site/">"site" repository</link>.
		Thus to change 
		any of the files at the root of http://xml.apache.org/ you would 
		first check out the "site" repository from svn.apache.org
	  </p>

      <section id="web-forrestbot-publish">
        <title>ForrestBot "publish" Step-by-Step</title>
        <p>
          We're using ForrestBot for build and deploy the XML website.
          ForrestBot comes with Apache Forrest 0.8 (install forrest and set
          FORREST_HOME and PATH as described
          <link href="#web-local-forrest">below</link>).
          The root directory of your XML site checkout contains the file
          "publish.xml" which is an Ant build file that manages the build and 
          the deployment of the XML website. Please look into this file for
          further instructions to set up ForrestBot on your machine. Basically,
          we're simply using ForrestBot manually by typing
          <code>"forrest -f publish.xml"</code> after we're happy with our
          changes to the site. Step-by-step instructions for the deployment
          process again:
        </p>
        <ul>
          <li>
            Modify the sources of the website and check locally with
            Forrest 0.8 (e.g. do "forrest run").
          </li>
          <li>
            Once you're satisfied, do <code>"forrest -f publish.xml"</code> to
            do a clean build of the website. If the build completes without
            problems, the website will be uploaded to the Subversion repository
            at <code>https://svn.apache.org/repos/asf/xml/site/targets/</code>.
          </li>
        </ul>
        <p/>
      </section>
      <section id="web-local-forrest">
        <title>Using a Local Forrest</title>
        <p>To use a local Forrest (during website development, not for deployment):</p>
        <ul>
          <!--li><link href="http://forrest.apache.org/mirrors.cgi#closest">download</link> latest the Forrest release (currently Forrest 0.7)</li-->
          <li>Due to <link href="http://issues.apache.org/jira/browse/FOR-555">bug FOR-555</link> we cannot 
              use the latest Forrest release. Please download the <strong>forrest_07_branch</strong> branch 
              (<link href="http://svn.apache.org/repos/asf/forrest/branches/forrest_07_branch">http://svn.apache.org/repos/asf/forrest/branches/forrest_07_branch</link>).</li>
          <li>set environment variable FORREST_HOME=~ (where ~ is the directory where Forrest is installed)
              (see <link href="http://forrest.apache.org/docs/your-project.html">http://forrest.apache.org/docs/your-project.html</link> for details)</li>
          <li>set environment variable PATH=$PATH:$FORREST_HOME/bin</li>
          <li>cd to your local XML site checkout</li>
          <li>update your local XML site checkout (svn update)</li>
          <li>do 'forrest run' and view localhost:8888, or do 'forrest'
            which will build the web-site documents in build/site for local viewing.</li>
        </ul>
        <note>
          You can use "forrest run" to start a local web server. That improves development speed as you 
          can simply refresh in the browser after a change. Point your browser to http://localhost:8888/ 
          to review the site in this case.
        </note>
      </section>
      <section id="delete">
        <title>Deleting Documentation Files</title>
        <p>
          ForrestBot simply uploads the whole generated site. It doesn't delete obsolete files. You
          can do that manually in the /www/xml.apache.org/ folder on cvs.apache.org. Be careful
          when doing stuff like that.
        </p>
        <note>
          Please make sure you always have <strong>group rw permissions on all files</strong> under the /www directory!
        </note>
      </section>

	  <section id="website-sub-forrest">
		<title>Updating Forrest based sub-project websites</title>

        <p>The sub-projects generate their website from their own sources and
          put the result into the relevant project directory, i.e.
          <code>/xml/site/targets/[your-project]/</code>
        </p>
        <p>To use <link href="http://forrest.apache.org/">Forrest</link>
          for your project install it
          <link href="http://forrest.apache.org/docs/your-project.html">as described</link>,
          then cd in the directory of your project and run "forrest". Publish the
          HTML/PDF result of the build into the xml-site/targets module (copy
          the results of ./build/site/ to /xml/site/targets/your-project/ and commit changes).
          The sources of the top-level xml.apache.org website are in the
          <jump href="http://svn.apache.org/repos/asf/xml/site/src/documentation/">/xml/site/src/documentation/</jump> directory.
		</p>
	  </section>
	  <section id="website-sub-other">
		<title>Updating non-Forrest sub-project websites</title>
		<p>
		  To update a part of the website (that does *not* use Forrest) do this:
		  <br/>Checkout the /xml/site module (you only actually need a few subdirs,
			but the whole thing is quite large).
			<br/>Make updates to your .xml files in the /xml/site/sources/your-project
		  directory.
		  <br/>Go to the /xml/site/sources directory locally and run the relevant
		  shell or bat script.
		  <br/>Check that the .html structure in your local targets directory is
			built correctly.
			<br/>Checkin to SVN both your updated sources/ and 
			<jump href="http://svn.apache.org/repos/asf/xml/site/targets/">targets/</jump>
			trees as needed,
		  <br/>Either login to cvs.apache.org and cd to /www/xml.apache.org and
		  do an update of directories there as needed,
		  <br/>Or send an email to infrastructure&lt;at&gt;apache.org and ask for
			your website to be added to the cronjob for automatic update.
<!-- FIXME: This secret link is a workaround to issue
http://issues.apache.org/jira/browse/FOR-480
-->
<link href="mirrors.html"/>
		</p>
	  </section>
	</section>
  </body>
</document>
