Thomas Deselaers
2009-Nov-29 12:49 UTC
[webgen-users] problem with output.do_deletion: true
Hi, I created a new webpage with webgen, and I really like it. Great work. I just restructured my src directory in order to make it a bit cleaner and therefore wanted to have files deleted if their source is not existing anymore. Therefore, I added output.do_deletion: true to config.yaml With this enabled, I get this error: Starting webgen... Updating tree... An error has occurred: Error while working: No such file or directory - MYDIRECTORY/out/publications/all_publications.html#journal_articles Although, I did not even change this file When removing the output.do_deletion configuration, everything works smoothly. any hints, what I am doing wrong? cheers, thomas -- http://thomas.deselaers.de
> Therefore, I added > output.do_deletion: true > to config.yaml > > With this enabled, I get this error: > > Starting webgen... > Updating tree... > An error has occurred: > Error while working: > No such file or directory - > MYDIRECTORY/out/publications/all_publications.html#journal_articles > > Although, I did not even change this file > > When removing the output.do_deletion configuration, everything works > smoothly. > > any hints, what I am doing wrong?From the error message and the given path, I think you are doing nothing wrong - it''s webgen fault. The path can''t actually exist on the filesystem since it is a fragment path, ie. part of a file path. I have added a TODO item and will fix this in the next release. What you should know about `output.do_deletion` is that it can only delete files if knows about, ie. which are in the cached tree (normally stored in the file webgen.cache). If you have already run webgen without the option set to `true`, then the old files won''t be deleted anymore since webgen doesn''t know about them anymore. The simplest thing you can do then is to delete the output directory and the webge.cache file and run webgen again. -- Thomas
Thomas Deselaers
2009-Nov-30 08:09 UTC
[webgen-users] problem with output.do_deletion: true
On Mon, Nov 30, 2009 at 07:20, Thomas Leitner <t_leitner at gmx.at> wrote:>> Therefore, I added >> output.do_deletion: true >> to config.yaml >> >> With this enabled, I get this error: >> >> Starting webgen... >> Updating tree... >> An error has occurred: >> ? Error while working: >> ? ? No such file or directory - >> MYDIRECTORY/out/publications/all_publications.html#journal_articles >> >> Although, I did not even change this file >> >> When removing the output.do_deletion configuration, everything works >> smoothly. >> >> any hints, what I am doing wrong? > > >From the error message and the given path, I think you are doing > nothing wrong - it''s webgen fault. The path can''t actually exist on the > filesystem since it is a fragment path, ie. part of a file path. > > I have added a TODO item and will fix this in the next release.Great. Thanks.> What you should know about `output.do_deletion` is that it can only > delete files if knows about, ie. which are in the cached tree (normally > stored in the file webgen.cache). If you have already run webgen > without the option set to `true`, then the old files won''t be deleted > anymore since webgen doesn''t know about them anymore. The simplest > thing you can do then is to delete the output directory and the > webge.cache file and run webgen again.I did nearly that. I only deleted the out directory, not the cache. I will retry. Thanks, thomas -- http://thomas.deselaers.de