Subject: [PATCH v2 17/22] t/t4*: merge a "grep | sed" pipeline

From: "Beat Bolli" <[email-masked]>
Date: Fri, 15 Mar 2024 20:46:14 +0100

Signed-off-by: Beat Bolli <[email-masked]>
---
 t/t4002-diff-basic.sh | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/t/t4002-diff-basic.sh b/t/t4002-diff-basic.sh
index 7afc883ec374..cb3307010c1e 100755
--- a/t/t4002-diff-basic.sh
+++ b/t/t4002-diff-basic.sh
@@ -405,7 +405,7 @@ test_expect_success 'diff-tree -r B A == diff-tree -r -R A B' '
 
 test_expect_success 'diff can read from stdin' '
 	test_must_fail git diff --no-index -- MN - < NN |
-		grep -v "^index" | sed "s#/-#/NN#" >.test-a &&
+		sed "/^index/d; s#/-#/NN#" >.test-a &&
 	test_must_fail git diff --no-index -- MN NN |
 		grep -v "^index" >.test-b &&
 	test_cmp .test-a .test-b
-- 
2.44.0