A Lua diff library
diff.lua | ||
README.md |
LuaDiffer: A simple lua diff library
This is a simple lua module that performs a diff on two strings and returns a table of string chunks.
Example
make_diff = require "diff"
s1 = [[hello
to the
world]]
s2 = [[hello
at the
world]]
diff = make_diff(s1, s2)
diff:print{color=false}
Produces:
hello
- to the
+ at the
world