irmin icon indicating copy to clipboard operation
irmin copied to clipboard

implement line/word diff

Open samoht opened this issue 10 years ago • 10 comments

We don't currently merge two strings if both contents has been modified since the have branched from a common ancestor. To improve that, need to have a look at https://github.com/janestreet/patdiff but it seems to depend on https://github.com/janestreet/core_extended ... @diml any chance to have the patdiff library usable on mirage (ie. pure ocaml code) ?

samoht avatar Apr 08 '14 18:04 samoht

Looks like https://github.com/janestreet/core_extended/blob/master/lib/patience_diff.ml is pretty standalone and doesn't really need the rest of Core_extended.

avsm avatar Apr 08 '14 18:04 avsm

Yeah I think we can pull this file out of core_extended without problem. I'll look into it.

ghost avatar Apr 09 '14 08:04 ghost

I haven't looked at the code in detail yet, but would patience_diff.ml be enough or are there things needed from patdiff/lib?

ghost avatar Apr 10 '14 13:04 ghost

I think patience_diff.ml should be enough, though.

samoht avatar Apr 10 '14 14:04 samoht

I've created https://github.com/samoht/ocaml-patience which depends only on core_kernel

samoht avatar May 02 '14 16:05 samoht

OK, actually we'll do this too for the next release.

ghost avatar May 03 '14 09:05 ghost

We created https://github.com/janestreet/patience_diff, shall it replace the patience package in opam?

ghost avatar May 14 '14 13:05 ghost

Thanks! Yes, you can replace my temporary package, I'll update the Irminsule package.

samoht avatar May 14 '14 13:05 samoht

patience_diff will be in opam as soon as https://github.com/ocaml/opam-repository/pull/2062 goes through.

bmillwood avatar May 14 '14 13:05 bmillwood

See also https://github.com/gjaldon/simple-diff

samoht avatar Feb 08 '17 18:02 samoht