From: Junio C Hamano <gitster@pobox.com>
To: "René Scharfe" <l.s.r@web.de>
Cc: Git List <git@vger.kernel.org>
Subject: Re: [PATCH 2/2] add-patch: quit on EOF
Date: Sat, 25 Oct 2025 17:46:55 -0700 [thread overview]
Message-ID: <xmqqfrb6mqv4.fsf@gitster.g> (raw)
In-Reply-To: <13529bee-1e02-4c20-9461-6569312bfe4f@web.de> ("René Scharfe"'s message of "Sat, 25 Oct 2025 07:48:28 +0200")
René Scharfe <l.s.r@web.de> writes:
> diff --git a/t/t3701-add-interactive.sh b/t/t3701-add-interactive.sh
> index 851ca6dd91..071b78c355 100755
> --- a/t/t3701-add-interactive.sh
> +++ b/t/t3701-add-interactive.sh
> @@ -1431,4 +1431,15 @@ test_expect_success 'invalid option s is rejected' '
> test_cmp expect actual
> '
>
> +test_expect_success 'EOF quits' '
> + echo a >file &&
> + echo a >file2 &&
> + git add file file2 &&
> + echo X >file &&
> + echo X >file2 &&
> + git add -p </dev/null >out &&
> + grep file out &&
> + ! grep file2 out
> +'
> +
> test_done
Let's do this squashed in.
t/t3701-add-interactive.sh | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git c/t/t3701-add-interactive.sh w/t/t3701-add-interactive.sh
index 071b78c355..4285314f35 100755
--- c/t/t3701-add-interactive.sh
+++ w/t/t3701-add-interactive.sh
@@ -1438,8 +1438,8 @@ test_expect_success 'EOF quits' '
echo X >file &&
echo X >file2 &&
git add -p </dev/null >out &&
- grep file out &&
- ! grep file2 out
+ test_grep file out &&
+ test_grep ! file2 out
'
test_done
next prev parent reply other threads:[~2025-10-26 0:46 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-10-25 5:46 [PATCH 1/2] add-patch: quit without skipping undecided hunks René Scharfe
2025-10-25 5:48 ` [PATCH 2/2] add-patch: quit on EOF René Scharfe
2025-10-25 16:20 ` Junio C Hamano
2025-10-25 17:23 ` René Scharfe
2025-10-26 0:37 ` Junio C Hamano
2025-10-26 0:46 ` Junio C Hamano [this message]
2025-10-26 16:11 ` René Scharfe
2025-10-25 15:42 ` [PATCH 1/2] add-patch: quit without skipping undecided hunks Junio C Hamano
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=xmqqfrb6mqv4.fsf@gitster.g \
--to=gitster@pobox.com \
--cc=git@vger.kernel.org \
--cc=l.s.r@web.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.