LivelyKernel/LivelyKernel — pull request #234 by rksm (2014-02-22 05:12:00+00:00)
Title: Diff support

new diff interface that uses both the JsDiff lib and commandline diff (unified diff). lively.ide implements the following interface now:

```js
lively.ide.diff(stringA, stringB, options, thenDo)
lively.ide.diffURLs(urlA, urlB, options, thenDo) // fetch url contents and diff
lively.ide.diffFiles(fileA, fileB, options, thenDo) // diff files on server
lively.ide.diffJSON(jsonA, jsonB, options, thenDo) // pretty print json, then diff
lively.ide.diffMorphs(morphA, morphB, options, thenDo) // diff serialized morph representation
lively.ide.diffVersions(urlOrPath, versionA, versionB, options, thenDo) // diff files/objects that are part of the lively wiki DB
```

`options` is optional and can be `options = {type: 'chars'|'words'|'lines'|'css'|'wordsWithSpace'}`
`thenDo` is optional and can be a function that gets called with the diff.