lua.wetgenes.txt.diff.split
Use the delimiter to split a string into a table of strings such that each string ends in the delimiter (except for possibly the final string) and a table.concat on the result will recreate the input string exactly.
table = wtxtdiff.split(string,delimiter)
String is the string to split and delimiter is a lua pattern so any special chars should be escaped.
for example
st = wtxtdiff.split(s) -- split on newline (default)
st = wtxtdiff.split(s,"\n") -- split on newline (explicit)
st - wtxtdiff.split(s,"%s+") -- split on white space