From: Junio C Hamano <gitster@pobox.com>
To: Ayush Chandekar <ayu.chandekar@gmail.com>
Cc: git@vger.kernel.org, sunshine@sunshineco.com
Subject: Re: [PATCH] t6423: fix suppression of Git’s exit code in tests
Date: Tue, 04 Feb 2025 05:08:07 -0800 [thread overview]
Message-ID: <xmqqjza5x3go.fsf@gitster.g> (raw)
In-Reply-To: <20250204003815.61391-1-ayu.chandekar@gmail.com> (Ayush Chandekar's message of "Tue, 4 Feb 2025 06:08:05 +0530")
Ayush Chandekar <ayu.chandekar@gmail.com> writes:
> Do you see any other changes needed in this patch? Let me know if there's
> anything you want me to adjust, especially in my commit message. Since my
> previous attempt wasn't very suitable.
If I were to change something, there are two minor things, but they
are so minor that I'd be OK without these changes.
If this is supposed to be a part of microproject exchange (sorry, I
lost track), then I am also OK to do the second (and hopefully
final) iteration to give us a chance to practice.
If I were you and I chose to iterate one more time, I'd rephrase this
This commit ensures that Git's exit status is correctly propogated by:
- Avoiding pipes that suppress exit codes.
to more like
Instead of placing a git command on the upstream side of a pipe,
redirect its output to a file and process the file contents in
two separate steps to avoid losing the exit status.
Also I'd not redirect into "uniq", i.e. instead of
uniq <actual >tracked &&
I'd write
uniq actual >tracked &&
but as discussed with Eric, this "better style" is not followed by
existing code.
next prev parent reply other threads:[~2025-02-04 13:08 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-02-02 12:09 [PATCH] t6423: fix suppression of Git’s exit code in tests ayu-ch
2025-02-02 13:18 ` Meet Soni
2025-02-02 13:35 ` Eric Sunshine
2025-02-03 0:04 ` Junio C Hamano
2025-02-04 0:38 ` Ayush Chandekar
2025-02-04 13:08 ` Junio C Hamano [this message]
2025-02-05 14:28 ` [GSOC][PATCH v2] t6422: avoid suppressing " Ayush Chandekar
2025-02-05 20:47 ` Junio C Hamano
2025-02-06 5:08 ` [GSOC][PATCH v2] t6423: " Ayush Chandekar
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=xmqqjza5x3go.fsf@gitster.g \
--to=gitster@pobox.com \
--cc=ayu.chandekar@gmail.com \
--cc=git@vger.kernel.org \
--cc=sunshine@sunshineco.com \
/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.