From ed30df3ed2b804b8e6b9c17c54f64d95f2d04241 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tim=20D=C3=BCsterhus?= Date: Mon, 11 Apr 2022 19:58:29 +0200 Subject: [PATCH] Configure diff drivers for `php`, `phpt`, `c` and `h` in `.gitattributes` --- .gitattributes | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/.gitattributes b/.gitattributes index 5bee19d08d632..514999ffccfeb 100644 --- a/.gitattributes +++ b/.gitattributes @@ -13,7 +13,8 @@ /UPGRADING merge=NEWS /UPGRADING.INTERNALS merge=NEWS -# Enable commit diffs for binary PHP test files. Some PHP test files include -# special characters, such as ASCII control characters. Git recognizes these as -# binary and wouldn't generate diffs. -*.phpt diff +# Configure proper diff drivers to improve the context lines in the output +# of git diff and to improve token splitting for --word-diff. +*.phpt diff=php +*.php diff=php +*.[ch] diff=cpp