[Pmwiki-users] Expiring page revisions.

Pedro Miller Rabinovitch miller
Wed Oct 1 09:06:45 CDT 2003

On Wednesday 01 October 2003 10:28, Reimer Behrends wrote:
> Two problems: First, the above commands do not lock the Wiki, which
> means that normal editing via the web can interfere with them. Second,

True, very true. I didn't think of that. Meaning that one would either have to 
use the locking system from the server side (i.e., figure out how it works, 
which shouldn't be too hard) or use the PHP functions to do it (which is 
probably the best alternative now).

> you cannot just make a file both the source and destination of such a
> filter. If it's greater than the internal buffer size of the file
> operation, you will start overwriting it before you've completely
> read it.

Yeah, you're right of course. I wrote it like that mostly because it was a 
"conceptual script", a prototype. Big fan of backups writing here, I'd 
definetly use temporary files and an "undo log" directory, etc etc.

> In other words, don't do it like this. You run the risk of really
> messing up your data.

Right. Besides, the best solution would really be in PHP, since using PmWiki's 
functions to copy the data would (hopefully) make it compatible with future 
versions, whereas a change in the way data is stored (or locked) could really 
mess up the shell scripts.

Thanks for the input!



More information about the pmwiki-users mailing list