How can I compare arbitrary revisions of a post?

Revision history is useful.

It’s nice to be able to see the diff between any 2 adjacent revisions (revs 3 and 4, or revs 8 and 9), but this is really insufficient when a post has been changed substantially over time, or if someone makes a bunch of small changes saving each as they go, especially if they multiply revise those changes.

I very much need to be able to see the diff between, for instance, rev 3 (which I produced) and rev 9 (which is the current, having been changed by multiple edits by one or more colleagues) … because it doesn’t matter who made what changes, nor when (especially if later intervening edits undid some earlier edits); it only matters that I can see what now differs from when I last touched the post.

4 Likes

There is no way to do this at the current time.

1 Like

That’s exceedingly disappointing. Might it be on a roadmap somewhere?

It is not on any roadmap at the moment. I don’t think it would be super difficult to do, so there are some options:

  1. sponsor the feature by proposing a goal and budget in #marketplace
  2. work on building the feature and submitting a PR yourself
  3. sponsor the feature with a business or enterprise class hosting subscription at discourse.org/buy
6 Likes

It this still the case? I’d like to compare post versions to research ‘edit spam’ on our forum in the Data Explorer.

2 Likes

I just came across this issue myself today, when reading a long knowledge base topic on our internal forum. We also use Discourse Policy extensively and everyone on the team must acknowledge they’ve read and accept changes to poliy topics in the knowledge base when the policy version number is increased. Policy is a super handy feature!

Unfortunately, as the OP pointed out back in 2018, there appears to be no way to compare specific topic revisions. This means that if there have been multiple revisions between policy versions, you have to scroll through the entire document for each revision to compare changes with adjascent changes.

Historically, the current functioning has worked perfectly because topics were almost entirely about discussion and you don’t really need to or want to encourage editing of posts - though you do need some revision history for moderating purposes. But over the years we added features to make topics suitable for collaboratively creating a knowledge base of documentation. This includes the ability to wikify the OP, DiscoTOC - automatic table of contents, Discourse-docs: Documentation Management Plugin, Discourse Shared Edits, and of course policy.

So I would advocate for improving the UI around comparing and managing revisions.

Here’s what it looks like now, allowing you to compare a previous revision (left side) with the next newer revision (right side). The revision nav in bottom left corner lets you switch to the previous/next revision, or jump to the first or last revision.

Wikipedia is the obvious place to look for prior art because that’s also what people who edit wikis are familiar with. Help:Page history - Wikipedia has a video walking through the entire wikipedia revision system, which is crazy powerful, arcane and also overwhelming. I could see replicating this being an interesting project if someone wanted to contribute it, for sites that are really leaning heavily on wiki topics and where versioning is prioritized. Could it be a plugin?

For core, a smaller improvement to solve the OP is to replicate the “Difference between revisions” page - see screenshot below. It’s quite similar to discourse. Note the nav is in the heading and lets you navigate the left and right side independently to compare different versions. Also, the precise time and date of the revision is displayed whereas in discourse you have to mouseover to see the precise time and date.

1 Like