typeintandem / tandem

Typing in Tandem. Decentralized, cross-editor, collaborative text-editing!
Apache License 2.0
697 stars 20 forks source link

Emacs support? #125

Open tomjridge opened 6 years ago

rageandqq commented 6 years ago

Hi @tomjridge , thanks for your interest in Tandem! Currently, we only support Neovim and Sublime Text. While we do have plans to extend Tandem to other editors, I don't think we'll be developing an Emacs plugin anytime soon.

However, if you are interested in developing a Tandem plugin for Emacs, we'd be delighted to help out along the way and more than welcome Pull Requests. We wrote a how-to for developing Tandem plugins. Check out our wiki: https://github.com/typeintandem/tandem/wiki/Interacting-with-the-Tandem-Agent As long as your plugin conforms to that outline, it should work seamlessly with the Agent!

anarcat commented 6 years ago

@rageandqq could you clarify what the Tandem agent is exactly? i see that the neovim plugin requires the neovim Python2 client and node.js, is that how the agent works, with node.js? this repository only has Python code, so I'm a little confused regarding the node.js requirement there...

alexjgriffith commented 6 years ago

The crdt is run on node.js

geoffxy commented 6 years ago

@anarcat The Tandem agent implements all of the common functionality that all plugins need (e.g. managing peers in a session, sending messages between peers, etc.). We actually use the CRDT that powers Teletype under the hood. Since they implemented it in JavaScript, we need to take on the Node.js dependency in order to actually use it with the agent.

jscheid commented 6 years ago

I've got something work-in-progress here https://github.com/jscheid/tandem-emacs

It works pretty well when joining a session, hosting a session (and joining it with Sublime) seems broken in the agent?

alexjgriffith commented 6 years ago

@jscheid i've run into the same issue when trying to host via the command line and join via sublime. Looking at the log all I get are the following messages:

2018-03-15 00:19 INFO     Tandem UDPGateway is listening on ('', 4001).
2018-03-15 00:19 INFO     Tandem Agent has started.
2018-03-15 00:20 DEBUG    Received data from 192.168.0.116:60689.
2018-03-15 00:20 DEBUG    Received data from 192.168.0.116:60689.
2018-03-15 00:20 DEBUG    Received data from 192.168.0.116:60689.
2018-03-15 00:20 DEBUG    Received data from 192.168.0.116:60689.
2018-03-15 00:20 DEBUG    Received data from 192.168.0.116:60689.
2018-03-15 00:20 DEBUG    Received data from 192.168.0.116:60689.
2018-03-15 00:20 DEBUG    Received data from 192.168.0.116:60689.
2018-03-15 00:20 DEBUG    Received data from 192.168.0.116:60689.
2018-03-15 00:20 DEBUG    Received data from 192.168.0.116:60689.
2018-03-15 00:20 DEBUG    Received data from 192.168.0.116:60689.
2018-03-15 00:20 DEBUG    Received data from 192.168.0.116:60689.
2018-03-15 00:20 DEBUG    Received data from 192.168.0.116:60689.
2018-03-15 00:20 DEBUG    Received data from 192.168.0.116:60689.
2018-03-15 00:20 DEBUG    Received data from 192.168.0.116:60689.
anarcat commented 6 years ago

oh boy, how exciting! didn't expect that to happen so soon :) congrats on the author and keep it up! should we report issues there or here?

(this only makes licensing issues described in #131 even more pressing unfortuantly...)

alexjgriffith commented 6 years ago

@anarcat since we are not modifying their agent, and it is their agent that is communicating with the server it might be ok. Alternatively we can point it to another server.

anarcat commented 6 years ago

On 2018-03-15 14:50:45, Alexander Griffith wrote:

@anarcat since we are not modifying their agent, and it is their agent that is communicating with the server it might be ok. Alternatively we can point it to another server.

Well, the license on the emacs plugin itself is not a concern here. The concern is the license of the agent. You still have to use agent to operate the plugin, and so agree to its license. Changing the server doesn't resolve the fundamental non-freeness of the license... But I disgress, this is a discussion for the other issue. :)

anarcat commented 6 years ago

the license will change, so nevermind those comments :) whoohoo!

rageandqq commented 6 years ago

@anarcat @alexjgriffith The license has been updated! See https://github.com/typeintandem/tandem/pull/135. Hope this quells your concerns 😄

@jscheid That's awesome! I too didn't expect this to happen so soon. What version of python3 are you running locally? We verified that the agent works with python3.6+, and handling versioning issues (and potentially rethinking how we choose, version, and distribute Tandem's dependencies) is one of the issues our team is planning to address.

jscheid commented 6 years ago

I have Python 3.6.4 from homebrew.

Could it be a discrepancy between the version of the agent used by the Sublime plugin and the one I'm using?

alexjgriffith commented 6 years ago

Does it work with the vim plugin? I have tried using the same agent for both the Emacs extension and Sublime plugin and still could not host on Emacs.

jscheid commented 6 years ago

It turns out Emacs hasn't quite achieved sentience yet and didn't know to send the initial buffer when hosting a session without me telling it to... it should work better now.

kfogel commented 6 years ago

By the way, what are the criteria for getting it listed as the (or as "an") unofficial Emacs plugin in the README and on the home page?

anarcat commented 6 years ago

What's the status here? It seems that the plugin haven't changed since march, does it actually work? Should Emacs be included in the list of supported clients?