Hi Sébastien,

Sébastien Geindre wrote:
Hi all,

Everything is in the subject !!

In order to start a cocoon project, handle by maven and developped with eclipse, i'd like to use maven archetype metadata for cocoon.

Did you ear about it ?
The unreleased Cocoon 2.2 does offer this.

At the moment I think you have to compile the trunk in order to install some required resources in your local Maven repository. Resources which are not yet published to Maven repositories.

Using Eclipse or other IDE you can configure you SVN client with URL:
https://svn.apache.org/repos/asf/cocoon

Once you have the source at hand and provided you have Maven 2.0.4 or above installed you may go to your local cocoon_trunk directory and type:
mvn install

Some may say:
mvn clean install -Dmaven.test.skip=true

Then jump out of cocoon_trunk create a Cocoon Block:

mvn archetype:create \
    -DarchetypeGroupId=org.apache.cocoon \
    -DarchetypeArtifactId=cocoon-22-archetype-block \
    -DarchetypeVersion=1.0.0-M5-SNAPSHOT \
    -DgroupId=com.yourcomp \
    -DartifactId=testblock

cd testblock

mvn install

cd ..

mvn archetype:create \
    -DarchetypeGroupId=org.apache.cocoon \
    -DarchetypeArtifactId=cocoon-22-archetype-webapp \
    -DarchetypeVersion=1.0.0-M2-SNAPSHOT \
    -DgroupId=com.yourcomp \
    -DartifactId=testwebapp

Modify testwebapp pom.xml to add dependencies on testroot

cd testwebapp
mvn package jetty:run

And your Cocoon testblock is accessible at:
http://localhost:8888/testblock/


Sometimes Maven repositories causes problems, so here is a .m2/settings.xml config file (mirrors section) which works for me...

  <mirrors>

    <!-- For Cocoon 2.2 -->
    <!-- Denmark -->
    <mirror>
      <id>repo1.maven.org</id>
      <url>http://repo1.maven.org/maven2</url>
      <mirrorOf>central</mirrorOf>
    </mirror>
    <!-- Denmark -->
    <mirror>
      <id>mirrors.dotsrc.org</id>
      <url>http://mirrors.dotsrc.org/maven2</url>
      <mirrorOf>central</mirrorOf>
    </mirror>
    <!-- United States, somewhere
    <mirror>
        <id>repo.mergere.com</id>
        <url>http://repo.mergere.com/maven2</url>
        <mirrorOf>central</mirrorOf>
    </mirror>
    -->
    <!-- United States, Louisiana
    <mirror>
      <id>lsu.edu</id>
      <url>http://ibiblio.lsu.edu/main/pub/packages/maven2</url>
      <mirrorOf>central</mirrorOf>
     </mirror>
    -->
    <!-- United States, North Carolina
    <mirror>
      <id>ibiblio.net</id>
      <url>http://www.ibiblio.net/pub/packages/maven2</url>
      <mirrorOf>central</mirrorOf>
    </mirror>
    -->
    <!-- Australia, Queensland
    <mirror>
      <id>planetmirror.com</id>
      <url>http://downloads.planetmirror.com/pub/maven2</url>
      <mirrorOf>central</mirrorOf>
    </mirror>
    -->
    <!--
    <mirror>
      <mirrorOf>central</mirrorOf>
      <id>ibiblioAustralianMirror</id>
      <url>http://public.planetmirror.com/pub/maven2</url>
    </mirror>
    -->
  </mirrors>


Please check the dev list for more info on running/developing with Cocoon 2.2 .

I think the developers will be pleased to have feedback on your success/problems. Your may post back to dev-list: dev@cocoon.apache.org if you like.

Patrick


sébastien.


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to