Commit graph

45 commits

Author SHA1 Message Date
Rodrigo Fernandes
3c06b401b9
feature: Add maxLineSizeInBlockForComparison to avoid OOM
Fixes #220
2019-06-14 17:10:31 +01:00
Mohamed Akram
e4e0df62b9 Preserve tabs 2019-04-15 20:26:32 +04:00
Nick Brewer
9c30d10b97 Fix trailing comma lint issue. 2019-01-31 18:18:24 -06:00
Nick Brewer
b43cc1ae91 Add configuration option to disable the render of templates.
No template would render if the diff shows no difference in its comparison.
2019-01-31 17:58:48 -06:00
Rodrigo Fernandes
7fbc8c238a
Improve line-height 2018-11-18 15:38:46 +00:00
stockmind
a222ff624c Target and style blank lines in side-by-side view 2018-11-14 22:18:39 +01:00
romellem
5215321466 Fixes regex for timestamps to when behind GMT
Currently, a timezone that ends in say '+0200' will get stripped, but a
timezone _behind_ GMT will not (so a timezone in the United States of
say, '-0400' will **not** get stripped.

This regex change fixes that.
2017-10-09 09:34:55 -05:00
romellem
ea43094ed6 Adds failing test for timezones behind GMT 2017-10-09 09:34:44 -05:00
Rodrigo Fernandes
267748f967
Fix escaping in header lines 2017-03-18 00:11:55 +00:00
Rodrigo Fernandes
ba239b6f15
Update dependencies 2016-12-17 23:53:30 +00:00
Rodrigo Fernandes
0f2d650436
Parse binary patch diffs 2016-12-01 16:39:01 +00:00
Paulo Bu
a481fad7ca Remove timestamps from filenames in unified diffs 2016-10-25 13:48:00 +02:00
Rodrigo Fernandes
f3cadb9667
Allow uncompiled templates 2016-10-15 13:31:02 +01:00
Rodrigo Fernandes
2aaae31cc2 Initial template override support 2016-10-15 13:00:31 +01:00
Rodrigo Fernandes
2a18c91e70
Add another way to recognize binary file names 2016-10-08 15:55:30 +01:00
Rodrigo Fernandes
0b3c3986c5
Fix eslint setup 2016-09-10 14:15:33 +01:00
Rodrigo Fernandes
6a47f8f3a5
Fix convert &nbps; to proper white spaces with white-space wrap 2016-09-05 22:34:18 +01:00
Rodrigo Fernandes
ed8d33930d
Fix git diff with renames and hunk headers
When we have the file names we consider that the file is already past
the hunk header (@@) and since the renames were setting the names
before the diff was confused.
To fix this I kind of hacked a solution that only uses the rename
file paths if there is no hunk header comming.
We need to find a better way to decide when to start new hunk, finish
files etc
2016-09-02 17:45:35 +01:00
Rodrigo Fernandes
9bbc87ae89
Fix parsing of binary files 2016-07-12 16:18:42 +01:00
Rodrigo Fernandes
f2858f6c45 Fix parsing in cases where body lines can be confused with header lines 2016-06-28 22:15:03 +01:00
Rodrigo Fernandes
7c79cc32db Fix parsing body lines starting with --- and +++ 2016-06-27 21:13:25 +01:00
Rodrigo Fernandes
fa9bdebe4c
Update tests for new design improvements 2016-05-21 02:09:16 +01:00
Rodrigo Fernandes
285c3fefc5
Improve rename paths
* Identify smallest different sub path of the changed files paths and
highlight the changed part
2016-05-20 23:17:03 +01:00
Rodrigo Fernandes
cb145eddf6
Add support for parsing unified diffs
* Refactor code to separate parser parts
* Add test for unified example
2016-05-06 23:02:05 +01:00
Rodrigo Fernandes
f08137f8ba
Improve branch coverage 2016-04-25 19:30:38 +01:00
Rodrigo Fernandes
2463cb0270
Add more tests to hogan templates 2016-04-25 17:53:54 +01:00
Rodrigo Fernandes
67ba95e5df
Add more tests to utils 2016-04-25 17:33:43 +01:00
Rodrigo Fernandes
4785c032a5
Add more tests for the diff2html api 2016-04-25 17:12:27 +01:00
Rodrigo Fernandes
e35b80a478
Add more tests for line by line diff generation 2016-04-25 16:51:27 +01:00
Rodrigo Fernandes
3fd5eb86bb
Fix parsing of line numbers 2016-04-25 16:20:40 +01:00
Rodrigo Fernandes
0261b30a26
Fix tests 2016-04-25 15:52:20 +01:00
Rodrigo Fernandes
374265354e
Add more tests and fix index parsing 2016-04-25 12:17:04 +01:00
Rodrigo Fernandes
465dde689a Fix repeated variable name in same scope (thanks Codacy) 2016-02-24 00:13:43 +00:00
Rodrigo Fernandes
e44b2a2885 Fix filename parsing with special characters and prefixes
* Add support for diffs with prefixes through configuration
* Fix parsing of filenames with special chars
2016-02-23 18:21:34 +00:00
Paulo Bu
e15cde2d6f Adds test for whitespaces and indentation and adds template for the wrapper 2016-02-21 11:05:53 +00:00
Paulo Bu
da2cd63a75 Attempt to use nunjuck templates in Line By Line 2016-02-21 11:05:53 +00:00
Rodrigo Fernandes
93dd322382 Add more eol tests for old os x and mixed eols 2016-02-07 12:47:00 +00:00
Rodrigo Fernandes
269a6268c4 Fix parsing on Windows
Replace windows EOL by Unix EOL
2016-02-06 18:50:47 +00:00
Rafael Cortês
f7bc1552e5 Fix line count when EOF is added to file
Removes '\\ No newline at end of file' information from the diff lines.
The test case is based on Bitbucket's diff attached to issue #49.
2016-01-16 21:53:54 +00:00
Paulo Bu
f6a9ecf450 Add tests to generateSingleLineHtml for SideBySide tests 2015-12-30 22:01:41 +01:00
Paulo Bu
97eafcd2f7 Add tests to generateLineHtml for LineByLine tests 2015-12-27 11:08:24 +01:00
Rodrigo Fernandes
f3d2946aa4 Force JSCS style 2015-12-23 19:34:39 +00:00
Rodrigo Fernandes
7244f07e0a Test html line prefixes 2015-12-23 16:05:30 +00:00
Paulo Bu
09d422be79 Adds simple tests for utils and diff2html 2015-12-23 14:14:29 +01:00
Rodrigo Fernandes
9e550c2b65 Start using mocha with istambul to test and setup circleci 2015-12-22 15:48:33 +00:00