[Moin-user] Nightly update of page

Nir Soffer nirs at actcom.net.il
Mon Sep 5 04:26:06 EDT 2005


On 5 Sep, 2005, at 10:55, Jens Jorgen Mortensen wrote:

> I have a page in my wiki, that contains some text and an image (an
> attachment).  I would like both text and image to be updated nightly by
> a crontab job.  Can I simply have my crontab job overwrite these files?
>
> data/pages/TestPage/revisions/00000001
> data/pages/TestPage/attachments/image.png

It should work, but has few problems:
  * You will loose the history of the page
  * The page edit-log will show wrong date
  * The wiki edit-log will show wrong date
  * If you use Lupy indexed search, the index will not be updated with 
the new text in the page
  * Any feature that triggered by the wiki edit log date might break

The best way would be to run a python script that save a new page 
revision in a correct way. It can save without backups if needed.

Use this as example:
http://moinmoin.wikiwikiweb.de/ScriptMarket/AppendTextScript

It append text to the page. You can easily change it to replace the 
text. I think you can control the backups feature with an argument to 
the PageEditor constructor.

If you create a working script, please put it on ScriptMarket.


Best Regards,

Nir Soffer





More information about the Moin-user mailing list