From 533d567e479753a15523ffd73bb7a90922b1cb97 Mon Sep 17 00:00:00 2001 From: Josh Triplett Date: Thu, 29 Apr 2021 22:54:09 -0700 Subject: [PATCH] Mark huge rls-analysis test data files as binary to filter greps When doing a `git grep` (of rls or of rust-lang/rust with `--recurse-submodules`), if the grep happens to match within the huge rls-analysis test data files, the resulting multi-megabyte single-line can cause a text pager to grind to a halt and have trouble scrolling (especially scrolling backwards). These test data files are autogenerated and aren't formatted for human consumption, so mark them as binary, which causes `git grep` to instead just state that they match without printing the matching "line". --- .gitattributes | 2 ++ 1 file changed, 2 insertions(+) create mode 100644 .gitattributes diff --git a/.gitattributes b/.gitattributes new file mode 100644 index 0000000000..2bd1ff3fe3 --- /dev/null +++ b/.gitattributes @@ -0,0 +1,2 @@ +rls-analysis/test_data/rls-analysis/*.json binary +rls-analysis/test_data/rust-analysis/*.json binary