Sha256: 242ffc5163b566b9a0bf4b93e4f3fac8c7ddd7f64738cf99e083b7087089acb5
Contents?: true
Size: 515 Bytes
Versions: 14
Compression:
Stored size: 515 Bytes
Contents
module Grit class Diff def old_path GritExt.encode! @a_path end def new_path GritExt.encode! @b_path end def diff if @diff.nil? @diff = "" else lines = @diff.lines.to_a path = GritExt.encode! lines.shift(2).join body = GritExt.encode! lines.join begin @diff = path + body rescue Encoding::CompatibilityError @diff = GritExt.clean(path) + GritExt.clean(body) end end end end end
Version data entries
14 entries across 14 versions & 1 rubygems