help-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Creating a read-only 'slave' buffer on a remote emacs instance


From: Ben Swift
Subject: Creating a read-only 'slave' buffer on a remote emacs instance
Date: Thu, 29 Aug 2013 17:05:40 +1000

Hi folks

I'm trying to set up a 'shared buffer' type distributed emacs scenario. The 
scenario is:

- there are two emacs users (user A and user B) who connected over a ssh tunnel.
- users A and B are each running their own emacs (on OSX, v24.3+), with their 
own config file, etc
- users A and B are each running graphical (non-text) emacs windows
- user A wants real-time *read-only* access to a buffer in user B's emacs
- user B wants  real-time *read-only* access to a buffer in user A's emacs
- I'm happy to use external elisp libs, and I trust the other person, so 
security's not such a concern*.  

I've tried some of the other collaborative editing options suggested on the 
wiki [1,2], but they all fall down one way or another 

- emacsclient is no good, because we want to be running different emacs 
instances, just sharing specific buffers
- I've tried Rudel [2], but I've found it to be unworkably unreliable
- I'd really like to keep running our graphical clients, so screen/tmux based 
workflows are out

Ultimately, I just want some way of sharing the emacs buffer object between 
remote emacsen, where in each case one end only has read-only access.  This 
makes it easier than the true 'collaborative editing' problem, which requires 
handling editing conflicts.

Worst comes to worst, I can hand-roll a custom solution which involves 
serialising the buffer object (in particular the text and the portion of the 
buffer currently in view, so that the slave follows the master as they navigate 
around the file) and sending it over the wire (from master to slave) at a 
reasonable refresh rate.  But if there's a nicer way to do it then I'm all ears.

Anyway, sorry about the long email.  Hopefully someone can point me in the 
right direction

Cheers,
Ben

[1] http://www.emacswiki.org/emacs/CollaborativeEditing
[2] 
http://stackoverflow.com/questions/12546722/using-emacs-server-and-emacsclient-on-other-machines-as-other-users
[3] http://sourceforge.net/projects/rudel/

* obviously I'm still concerned about security from the outside world, but I 
trust user B to not do anything malicious.  I'm even happy to give them access 
to my user account.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]