This page demonstrates my custom
CodeMirror
diff highlight. Examples are from
Wikipedia
.
Normal Diff:
0a1,6 > This is an important > notice! It should > therefore be located at > the beginning of this > document! > 8,14c14 < compress the size of the < changes. < < This paragraph contains < text that is outdated. < It will be deleted in the < near future. --- > compress anything. 17c17 < check this dokument. On --- > check this document. On 24c24,28 < be added after it. --- > be added after it. > > This paragraph contains > important new additions > to this document.
Context Diff:
*** /path/to/original ''timestamp'' --- /path/to/new ''timestamp'' *************** *** 1,3 **** --- 1,9 ---- + This is an important + notice! It should + therefore be located at + the beginning of this + document! + This part of the document has stayed the same from version to *************** *** 5,20 **** be shown if it doesn't change. Otherwise, that would not be helping to ! compress the size of the ! changes. ! ! This paragraph contains ! text that is outdated. ! It will be deleted in the ! near future. It is important to spell ! check this dokument. On the other hand, a misspelled word isn't the end of the world. --- 11,20 ---- be shown if it doesn't change. Otherwise, that would not be helping to ! compress anything. It is important to spell ! check this document. On the other hand, a misspelled word isn't the end of the world. *************** *** 22,24 **** --- 22,28 ---- this paragraph needs to be changed. Things can be added after it. + + This paragraph contains + important new additions + to this document.
Unified Diff:
--- /path/to/original ''timestamp'' +++ /path/to/new ''timestamp'' @@ -1,3 +1,9 @@ +This is an important +notice! It should +therefore be located at +the beginning of this +document! + This part of the document has stayed the same from version to @@ -5,16 +11,10 @@ be shown if it doesn't change. Otherwise, that would not be helping to -compress the size of the -changes. - -This paragraph contains -text that is outdated. -It will be deleted in the -near future. +compress anything. It is important to spell -check this dokument. On +check this document. On the other hand, a misspelled word isn't the end of the world. @@ -22,3 +22,7 @@ this paragraph needs to be changed. Things can be added after it. + +This paragraph contains +important new additions +to this document.