Now before you shoot me for bringing up a duplicate question on SOF, let me first acquaint you with exactly what I'm looking for, and I will address other questions and answers and why it is insufficient.
Question #1:
I'm looking for a way to perform live collaborative edits, while the source is maintained on a centralized source control server. For example, if Me and Joe Blow are editing file X.cs
at the same time, we should be able to see each-other's edits as we type. Almost as if we were sitting together at the same computer. Now take the following scenario: Me and Joe go offline, and Nimha Smith decides she wants to update some code. When I come back online the following day, I get pushed the code that Nimha updated while I was sleeping/away from the server.
This is a combination of the idea of live collaboration, and a source control system like SVN, etc.
Addressing of the possible duplicates:
There was a similar question, here: Collaborative editing for .NET development - what are the possibilities, however it does not give me anything useful and I'll explain why:
And there is obviously this question and this one that are questions directly about source control software such as SVN or GIT. Now, I tried to get VSAnywhere and SVN to play nice together, (SVN for getting changes made while offline, and VSAnywhere for the online developers) but it simply does not work.
<edit>
I recently found this bachelor thesis project named Collab, and it seems like a good idea, but I could not seem to get it working to try it. If anyone else has any success with it please let me know what you did. It looks like if I can get this collab project working it seems like it would be a good start into creating something to fit my needs.
<edit2>
I've also come across BeWeeVee which had a Visual Studio extension for it's service, but all the links for it have gone dead. And CodeALike which was probably their replacement for VS real-time collaboration has a FAQ entry explaining that it's real-time features have been removed and will be re-implemented in the "future".
Question #2:
Now this brings me to the second part of my question because I fully realise there may not be a program out there that fits my tall order. Where could I start implementing software such as this myself? Are there some existing open-source source-control / real-time editing code that I can begin to build off of to create this? Or am I pretty much stuck starting from scratch if I want to implement this. And I'm sure you can see by the tags that I would like to tackle a task like this in C#, if I have to tackle it at all.
As there has been some continued interest expressed in the comments I've created a gitter where we can gather anyone interested and potentially make this a reality: https://gitter.im/sof-centrailized-collab-editing/Lobby.
Share your code, collaborate on anything, anywhere, anytime No need to clone a repo or set up the environment, to get sharing.
What is Live Share? # Live Share enables you to quickly collaborate with a friend, classmate, or professor on the same code without the need to sync code or to configure the same development tools, settings, or environment.
How much will it cost? We are committed to a substantive free tier of Visual Studio Live Share for developers to use on an ongoing basis.
You can disable Live Share in Visual Studio Installer. When installer window opens, select your instance of Visual Studio, click “Modify” and uncheck “Live Share” component.
If you want to tackle this yourself, you might like to do it as a Visual Studio extension. Notice that there are two different types of plug-ins: “add-ons” and “extensions”. Personally I think you should write an extension, but either way, you can write them in C#.
You will need to hook into Visual Studio’s text editor. You could either google for how to do this, or just look at an existing example: a Visual Studio extension for elastic tabstops. Your extension will have to monitor your changes as you make them and then send them to the server via some protocol you design. You’ll have to write the server yourself, but in the first version all it needs to be able to do is just send your edits to everyone else who is using the extension. The extension would then make everyone’s edit in everyone else’s editor.
If someone connects to the server with an older version of the code, the extension could just download the newest version from the server. However, if the user has made edits while offline (i.e. while not connected to the server), then you will need to do some clever merging. This is non-trivial, but I know how to do it because I’ve done it before. If you ask very nicely, I’ll write the merge algorithm for you. Then you’ll only need to feed it three text files: the base (the version that was last in sync with the server) and the two edited versions (the one edited offline and the newest from the server).
If you manage to get this to work, you will potentially create something invaluably useful. Please do make sure that you publicise your work! :)
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With