cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Alessio Sangalli <>
Subject Using Cocoon from the command
Date Sun, 10 Nov 2002 20:11:57 GMT
For the first time in a year and a half I want to use Cocoon from the 
command line. I will be able to use the results in an environment 
without Cocoon or Java and I won't have to generate every time the data 
etc etc.

I use Sun's JDK 1.4.1_01, Cocoon 2.0.3, on Linux.

I've found at least of informations on dejanews and the mail list archives:

Uh, I should have looked at the code!
I answered my own simple question. For reference:
java -classpath . org.apache.cocoon.Main  --help



You can use Cocoon command line interface.

java org.apache.cocoon.Main -c<sourcepath> -d<resultpath>  -w<tmppath> \
-l<logfilename>  -uINFO -f<list.uris>

sourcepath : where your cocoon files are, with the sitemap and so on
resultpath : where tour HTML files go
tmppath    : a directory for tmp files
logfilename : the log file
list.uris : a file containing the list of URI your want to build using 

good, however WHERE should I give those command lines?

I've never compiled Cocoon by sources because in the early days of the 
2.0beta it was a pain in *** ***, and I used to download the binary 
.war. However this time I had to, because Main.class wasn't avaiable 
anywhere on a binary distribution only.

$ sh build all

will create cocoon.jar but I can't get it working; at best I get a

$ java -classpath . org.apache.cocoon.Main
Exception in thread "main" java.lang.NoClassDefFoundError: 
         at java.lang.ClassLoader.defineClass0(Native Method)
         at java.lang.ClassLoader.defineClass(
etc etc etc..........

I tried to unzip the jar, to go directly inside and call Main.class from 
its own dir, etc

what can I do...!

bye & thank you

Please check that your question  has not already been answered in the
FAQ before posting.     <>

To unsubscribe, e-mail:     <>
For additional commands, e-mail:   <>

View raw message