Wilfred Hughes
5a51c02157
Fix crash when the last hunk includes the trailing newline at EOF
...
Input cleaning should happen before we diff the content, not during
display. Previously display would crash due to line numbers
referencing the line that had been stripped.
Fixes #713
Fixes #739
Fixes #742
2024-07-26 08:54:20 +07:00
Wilfred Hughes
c2f4b1f2ee
Update tests and changelog for 1e8be4558b
2024-07-21 11:15:54 +07:00
Wilfred Hughes
92fa3fb3de
Ensure files with no common content are aligned
2024-07-20 23:43:04 +07:00
Wilfred Hughes
fa2ec359d7
Roll version
2024-07-20 16:11:55 +07:00
Wilfred Hughes
ffe27c575e
Ensure line splitting distinguishes "foo" and "foo\n"
...
We rely on being able to split lines and rejoin them to obtain the
original string. `str::lines()` in the Rust stdlib does not have this
property.
This was causing crashes in word-diffing on textual diffing, where
code paths differed on the number of lines they thought a string had.
This was broken in 8b842387a1 .
Fixes #688 .
2024-07-20 16:09:44 +07:00
Wilfred Hughes
a259c858a1
Update F# docs
2024-05-14 10:13:37 +07:00
Wilfred Hughes
d292546df7
Prefer 'device tree' as two words
2024-05-13 16:59:48 +07:00
Wilfred Hughes
de9c84c418
Document new addition
2024-05-13 16:52:33 +07:00
Wilfred Hughes
28d8673371
Treat tree-sitter nodes highlighted as comments as atoms
...
Fixes #711
2024-05-11 22:03:59 +07:00
Wilfred Hughes
835c5eb757
Roll version following release
2024-05-11 13:54:42 +07:00
Wilfred Hughes
0c9277108b
It's not actually a 2x perf win
...
It's more like a 15% reduction in instruction count, which is still
nice.
2024-05-10 16:28:16 +07:00
Wilfred Hughes
edb839c803
Improve terminal width detection
...
Ensure the value is always non-zero, and consider $COLUMNS if
crossterm does not succeed.
Fixes #707
2024-05-10 16:26:48 +07:00
Wilfred Hughes
e23b9fc224
Update CMake parser
2024-04-28 23:53:12 +07:00
Wilfred Hughes
ecaee577b2
Update Elm parser
2024-04-28 23:50:29 +07:00
Wilfred Hughes
ae77a9cdf7
Document C++ parser change
2024-04-28 23:43:58 +07:00
Wilfred Hughes
27fb722ac7
Merge commit '1aafaff4d26dac5a36dd3495be33e1c20161d761'
2024-04-28 23:31:25 +07:00
Wilfred Hughes
cce7b2ee1b
Merge commit 'b466ffb4d7ce0a833754429ad8d3a02e950ed74c'
2024-04-28 23:00:00 +07:00
Wilfred Hughes
a5b2587eaa
Merge commit 'eb68645662a3f7bf7fdd4bcb9531585f54c8570e'
2024-04-28 22:54:18 +07:00
Wilfred Hughes
c2df185d49
Update Lua parser
...
Closes #701
2024-04-28 22:36:23 +07:00
Wilfred Hughes
2e016566ac
Update CSS parser
2024-04-28 21:45:25 +07:00
Wilfred Hughes
38f148df1f
Don't flatten error nodes
...
As of b9d44ae65f (released in 0.38), difftastic prefers a textual
diff if any parse errors are present. As a result, users have to
opt-in to allowing parse errors. We can now preserve structure to
produce diffs that are more granular, at the slight risk of changes
being missed if parsers discard tokens.
Fixes #703
2024-04-28 17:28:34 +07:00
Wilfred Hughes
d15d593708
Move to smallvec for seen vertices
...
This is a surprisingly large perf win. On my Thinkpad:
typing_before/after.ml:
before: 3.038B instructions
after: 2.870B instructions
slow_before/after.rs:
before: 2.381B instructions
after: 1.260B instructions (!)
2024-04-28 16:16:47 +07:00
Wilfred Hughes
d2cdb96e00
Expand man page and add to changelog
2024-04-28 15:07:23 +07:00
Wilfred Hughes
f52ca706f3
Enable --strip-cr by default
...
Line ending differences between input files often leads to confusing
diffs, so remove carriage returns unless explicitly requested.
Fixes #653
Fixes #696
2024-04-09 08:37:41 +07:00
Wilfred Hughes
db281c682c
Roll version
2024-04-02 08:17:24 +07:00
Wilfred Hughes
00e837aeb1
Update changelog
2024-04-01 22:42:16 +07:00
Wilfred Hughes
3be8e80fe7
Fix issue with later lines not having positions during diffing
2024-03-19 00:25:18 +07:00
Wilfred Hughes
34fa3d6eff
Use a blank line after all diff summaries
2024-03-07 08:19:58 +07:00
Wilfred Hughes
c6da85759c
Consider null bytes in text file detection
2024-03-06 23:07:59 +07:00
Wilfred Hughes
d3797ef4e2
Treat Scheme as a lisp in slider logic
2024-03-06 21:56:27 +07:00
Wilfred Hughes
2b19e59aeb
0.56.1 is released
2024-03-05 23:23:43 +07:00
Wilfred Hughes
d9d6401c45
Update ahash to fix aarch64 build on macOS
...
See upstream discussion in
https://github.com/tkaitchuck/aHash/issues/207
2024-03-05 22:12:11 +07:00
Wilfred Hughes
bf8fcab420
0.56 is released
2024-03-05 22:02:37 +07:00
Wilfred Hughes
247727066f
Handle whitespace in shebangs
2024-03-04 22:10:08 +07:00
Wilfred Hughes
d5c60241ef
Detect more Makefile naming patterns
2024-03-04 22:06:09 +07:00
Wilfred Hughes
407ab78cda
Document Scheme addition
2024-03-04 22:03:54 +07:00
Wilfred Hughes
b78f7d447b
Always replace tabs, even in single-column display
...
Fixes #617
2024-03-04 21:38:23 +07:00
Wilfred Hughes
d894a18142
Update perl parser
...
Upstream has made the generated parser.c much smaller too.
2024-03-03 12:40:51 +07:00
Wilfred Hughes
53298e4240
Set a length limit on lines when doing a word diff
...
See #653
2024-02-29 00:54:55 +07:00
Wilfred Hughes
bb9e864ffe
Fix permissions always shown as 'changed' with git-difftool
2024-02-20 00:17:38 +07:00
Wilfred Hughes
cbbcbb3094
Parse file mode properly from git and pass through
2024-02-20 00:07:06 +07:00
Wilfred Hughes
1cc0c42c20
Detect git difftool paths and prefer the second argument
...
Fixes #620
2024-02-19 22:19:20 +07:00
Wilfred Hughes
f99a8ce543
Update changelog for last PR
2024-02-19 12:02:30 +07:00
Wilfred Hughes
6f192d9207
Mention Smali in changelog
2024-02-19 11:59:27 +07:00
Wilfred Hughes
e52849ebba
Merge commit '9fa49ff3315987f715ce5666ff979a7742fa8a98'
2024-02-15 08:54:57 +07:00
Wilfred Hughes
58536b9426
Merge commit '7db8390a16a2cae317f4f4423a7b642cd4cad8c9'
...
Fixes #515
2024-02-13 08:38:53 +07:00
Wilfred Hughes
a721bef7a7
Merge commit '098bd31b7f838a31cce08db4091e989ea42f3ef6'
2024-02-13 08:36:21 +07:00
Wilfred Hughes
77c641748f
0.55 is released
2024-02-01 08:26:52 +07:00
Wilfred Hughes
29b3119f39
Mention #570 in changelog
2024-01-30 21:24:11 +07:00
Wilfred Hughes
052b3a62a3
Use XML file headers as language detection hints
...
Fixes #630
2024-01-30 21:22:51 +07:00