You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@forrest.apache.org by Fabio Rinaldi <ri...@ifi.unizh.ch> on 2004/08/09 14:45:11 UTC

File overwriting: bug or feature?

Dear Forrest team,

I have just verified that if I have in my 'raw content directory' a
file which has the same name as one of the files generated on the
basis of the contents of the 'xdocs' directory, and the two are
supposed to end up in the same directory, then the raw file overwrites
the generated file. Example: if I have "x.xml" in xdocs, this
generates "x.html" (and "x.pdf") in the site directory, however if I
have "x.html" (or "x.pdf") in my 'raw content' directory, then the
latter overwrites the former.

Perhaps this is the desired behaviour, but I would have expected at
least a warning during creation of the web site. Can this behaviour be
altered?

Best,
Fabio

Re: File overwriting: bug or feature?

Posted by Fabio Rinaldi <ri...@ifi.unizh.ch>.
Dave Brondsema writes:
 > 
 > The raw-content copy happens in parallel with the forrest generation of
 > files.  So actually it could happen either way (forrest overwrite raw, or
 > raw overwrite forrest).  I don't ever recall discussing which should take
 > precedence.  I would think raw.
 > 

Hi Dave,

thanks for your answer. I think users could live with either of the
policies: as long as it is clear which one! 

The fact that you say "it could happen either way" could be very
disconcerting and confusing. 

IMHO, the best solution is to let 'raw' take precedence over 'generated'
content, make this clear in the documentation, and issue a warning
when this happens.

Best,
Fabio

Re: File overwriting: bug or feature?

Posted by Dave Brondsema <da...@brondsema.net>.
On Mon, 9 Aug 2004, Fabio Rinaldi wrote:

>
> Dear Forrest team,
>
> I have just verified that if I have in my 'raw content directory' a
> file which has the same name as one of the files generated on the
> basis of the contents of the 'xdocs' directory, and the two are
> supposed to end up in the same directory, then the raw file overwrites
> the generated file. Example: if I have "x.xml" in xdocs, this
> generates "x.html" (and "x.pdf") in the site directory, however if I
> have "x.html" (or "x.pdf") in my 'raw content' directory, then the
> latter overwrites the former.
>
> Perhaps this is the desired behaviour, but I would have expected at
> least a warning during creation of the web site. Can this behaviour be
> altered?
>

The raw-content copy happens in parallel with the forrest generation of
files.  So actually it could happen either way (forrest overwrite raw, or
raw overwrite forrest).  I don't ever recall discussing which should take
precedence.  I would think raw.

-- 
Dave Brondsema : dave@brondsema.net
http://www.brondsema.net : personal
http://www.splike.com : programming
http://csx.calvin.edu : student org

Re: File overwriting: bug or feature?

Posted by Angeshwar Deepak <an...@yahoo.com>.
Hi,

I am not clear with 'raw-content', but I too did the
same thing I guess. Just check if this is what
happened to you.

I have some html files in c:\site dir. I use the tidy
tool to make them well formed, rename them to .ehtml
and put them all in src\documentation\content\xdocs
dir. Forrest takes all these files copies to
tmp\context\content\xdocs dir, converts .ehtml files
to html file and again put the html files to c:\site
dir. So I lost the old content in the c:\site dir.



--- Fabio Rinaldi <ri...@ifi.unizh.ch> wrote:

> 
> Dear Forrest team,
> 
> I have just verified that if I have in my 'raw
> content directory' a
> file which has the same name as one of the files
> generated on the
> basis of the contents of the 'xdocs' directory, and
> the two are
> supposed to end up in the same directory, then the
> raw file overwrites
> the generated file. Example: if I have "x.xml" in
> xdocs, this
> generates "x.html" (and "x.pdf") in the site
> directory, however if I
> have "x.html" (or "x.pdf") in my 'raw content'
> directory, then the
> latter overwrites the former.
> 
> Perhaps this is the desired behaviour, but I would
> have expected at
> least a warning during creation of the web site. Can
> this behaviour be
> altered?
> 
> Best,
> Fabio
> 



		
__________________________________
Do you Yahoo!?
New and Improved Yahoo! Mail - Send 10MB messages!
http://promotions.yahoo.com/new_mail