4

How does SO/SF/SU manage the Integrated revision control of the questions and answers? Did they use some open source library, or did they write their own system. Either way, I would really like to learn how to go about implementing the wiki feature in a ASP.Net MVC website, and I have know idea on where to start, in order to figure out how to implement such a feature. I'm not really asking for someone to give me fish, but rather teach me how.

3

I believe that each revision has the full text and the revision number in, and the diffs are generated when needed. After that it's pretty easy... it's not like there's branching and merging to worry about, like in source control systems.

| improve this answer | |
  • 1
    But how would one go about figuring out the diffs between the two full text items, and go about crossing-out/bolding the changes? – MrTomahawk Aug 14 '09 at 13:07
  • It's a fairly trivial algorithm -- tokenise both lists, advance through both (increment both on match, look ahead on both in a non match) - that will give you a list of decisions for each token - same, new or removed, which you can build markup from – Rowland Shaw Aug 14 '09 at 13:23
  • Sorry I'm new to this..does anyone know a website which walks through the process in any language? I'm sure the concepts are the same. – MrTomahawk Aug 14 '09 at 15:50

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .