forrest-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Thorsten Scherler <thorsten.scherler....@juntadeandalucia.es>
Subject Re: generate only pages changed since last static site build?
Date Fri, 21 Sep 2007 07:06:22 GMT
On Fri, 2007-08-31 at 16:43 -0700, Brolin Empey wrote:
> Brolin Empey <brolin.empey@gmail.com> wrote:
> > Tim:
> >
> > The Cocoon checksum feature sounds like it may work.  I will try it
> > when I return to work and will let you know the results.
> 
> The Cocoon checksum feature seems to work, but I have a configuration
> problem with specifying checksums-uri in cli.xconf.
> 
> I need checksums-uri to be relative to e.g. the root of my Forrest
> project (the directory containing forrest.properties and src/) so that
> I can use a relative path to a checksums file in my build/site/
> directory.
> 
> I do not want to hard-code an absolute path because this path will
> break if I move the SVN working copy of my Forrest site, or if someone
> else checks out a copy of my Forrest site.
> 
> I tried setting checksums-uri to just "checksums", but then the build
> process hangs when I run "forrest" to rebuild the static site because
> the JVM encounters a Java IO exception when attempting to write the
> checksums file.  This happens because I do not have write permission
> for whichever directory checksums-uri is relative to.  I tried
> enabling both verbose and debug output for both Forrest and the JVM,
> but when the JVM encounters the Java IO exception it still does not
> say which path it is trying to write to.
> 

Word of warning: I have not yet used this feature, so I am fishing in
the dark!

> So, my questions are:
> 
> 1. Which directory is checksums-uri relative to?

I reckon either the project.home or place.where.cli.file.exist.

> 
> 2. Is there any way to get the path of the file that could not be
> written when the JVM encounters a Java IO exception?  I am using Sun's
> JDK on Linux:

Have you looked in the logs? Normally an IO will throw a stacktrace
defining which file could not be found. See the logs in
build/webapp/WEB-INF/logs/*.log

> $ java -version
> java version "1.5.0_10"
> Java(TM) 2 Runtime Environment, Standard Edition (build 1.5.0_10-b03)
> Java HotSpot(TM) Client VM (build 1.5.0_10-b03, mixed mode, sharing)
> 
> 3. Can I make checksums-uri relative to e.g. the root of my Forrest
> project?  I notice I can set e.g. a context directory in cli.xconf,
> but I do not know what else is affected by this setting.
> 


Did you try?

http://marc.info/?l=forrest-dev&m=106552311203954&w=2 sounds like it can
be any path: "The checksum file can be stored on a server, e.g. using an
ftp:// URI (any URI for which a modifiable source exists)."

So you could use a "checksum server".

Another possibility is to generate the cli.xconf via a custom ant
build.xml and store the location in a build.properties file.

salu2

> If possible, I would like to avoid having to specify an absolute path
> to a temporary location, such as /tmp/checksums, and copy the
> checksums file back into my build/site/ directory.
> 
> Thanks,
> Brolin
-- 
Thorsten Scherler                                 thorsten.at.apache.org
Open Source Java                      consulting, training and solutions


Mime
View raw message