[Pmwiki-users] Emacs and simultaneous edits

chr@home.se chr
Sun Oct 3 19:44:43 CDT 2004


> > ** The lack of being able to use Emacs/pmwiki-mode is a showstopper here
> >    for efficiency reasons.
> 
> I'm afraid that one is in your court, as I don't use Emacs :-) .  
> However, the interface is almost entirely the same between v1.0 and
> v2.0, so you should be able to do basic editing (without simultaneous
> edit detection/handling) pretty much the same as before.

I just tried to use the existing pmwiki-mode to edit the sandbox (v2), and
although I can still retrieve the source (?action=source) as before,
changes are not written properly to the wiki page. The writing is done
using a http-post operation, but the result seems to be full HTML code for
a normal page. I can look closer at that if you think it'll contain
something of interest.

Do you think it is at all possible for pmwiki-mode to use the same method
for saving to both v1.0 and v2.0?  Or should I instead make pmwiki-mode
somehow detect which version of PmWiki it's talking to (and use different
methods to save a page)?

> In order for the editor to participate in simultaneous edit handling, it
> needs to be able to pass back the timestamp given in the page when
> ?action=edit was requested, and to see if the post was successful.  

I don't actually used ?action=edit, but rather ?action=source...  Using
?action=edit seems wrong for pmwiki-mode, since I'll get this other stuff
that I don't really need.

> (Or, if you trust your clock to match the server's clock closely enough,
> Emacs/pmwiki-mode could just use the time when the page was retrieved.)

That's not likely to work out of the box. It *might* work if pmwiki-mode
asks the server for the current time, and then compares this to the local
time, thus producing an estimate of the time difference (this would only 
have to be done once for each wiki server).

However, it seems like the best way for me to start on this is if I can
understand how it is supposed to work. Could you describe the algorithm
that's used by v2.0 for simultanoues editing?

/Christian

-- 
Christian Ridderstr?m, +46-8-768 39 44               http://www.md.kth.se/~chr





More information about the pmwiki-users mailing list