From: Junio C Hamano <gitster@pobox.com>
To: Jeff King <peff@peff.net>
Cc: Patrick Steinhardt <ps@pks.im>,
Johannes Schindelin via GitGitGadget <gitgitgadget@gmail.com>,
git@vger.kernel.org, Eric Sunshine <sunshine@sunshineco.com>,
Johannes Schindelin <johannes.schindelin@gmx.de>
Subject: Re: [PATCH v2 1/2] for-each-repo: optionally keep going on an error
Date: Mon, 22 Apr 2024 14:39:23 -0700 [thread overview]
Message-ID: <xmqqr0ext6us.fsf@gitster.g> (raw)
In-Reply-To: <20240419175621.GB14309@coredump.intra.peff.net> (Jeff King's message of "Fri, 19 Apr 2024 13:56:21 -0400")
Jeff King <peff@peff.net> writes:
> run_command() may also return the exit code of the program run. So
> imagine a setup like:
>
> git init
> git config alias.foo '!exit 123'
> git config repo.paths "$PWD"
> git for-each-repo --config=repo.paths foo
> echo $?
>
> Before the patch we see "123" and after we see "1".
True, or when the process receives a signal, etc. With this change,
we do lose information.
> I do agree that passing -1 to exit is bad; we maybe should normalize to
> 127 for not found, though I think we could also see -1 for system errors
> like fork() failing.
True, but I think that is a separate issue.
So, let's have a (hopefully final reroll to fix the error code when
stopping at the first error and merge it to 'next'?
Thanks.
next prev parent reply other threads:[~2024-04-22 21:39 UTC|newest]
Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-04-17 8:28 [PATCH 0/2] Use a "best effort" strategy in scheduled maintenance Johannes Schindelin via GitGitGadget
2024-04-17 8:28 ` [PATCH 1/2] for-each-repo: optionally keep going on an error Johannes Schindelin via GitGitGadget
2024-04-17 8:36 ` Eric Sunshine
2024-04-17 15:38 ` Junio C Hamano
2024-04-17 8:28 ` [PATCH 2/2] maintenance: running maintenance should not stop on errors Johannes Schindelin via GitGitGadget
2024-04-17 15:41 ` Junio C Hamano
2024-04-17 15:36 ` [PATCH 0/2] Use a "best effort" strategy in scheduled maintenance Junio C Hamano
2024-04-18 12:53 ` [PATCH v2 " Johannes Schindelin via GitGitGadget
2024-04-18 12:53 ` [PATCH v2 1/2] for-each-repo: optionally keep going on an error Johannes Schindelin via GitGitGadget
2024-04-19 4:24 ` Patrick Steinhardt
2024-04-19 16:03 ` Junio C Hamano
2024-04-19 17:56 ` Jeff King
2024-04-22 21:39 ` Junio C Hamano [this message]
2024-04-18 12:53 ` [PATCH v2 2/2] maintenance: running maintenance should not stop on errors Johannes Schindelin via GitGitGadget
2024-04-24 16:14 ` [PATCH v3 0/2] Use a "best effort" strategy in scheduled maintenance Johannes Schindelin via GitGitGadget
2024-04-24 16:14 ` [PATCH v3 1/2] for-each-repo: optionally keep going on an error Johannes Schindelin via GitGitGadget
2024-04-24 17:02 ` Junio C Hamano
2024-04-24 16:14 ` [PATCH v3 2/2] maintenance: running maintenance should not stop on errors Johannes Schindelin via GitGitGadget
2024-04-25 6:36 ` [PATCH v3 0/2] Use a "best effort" strategy in scheduled maintenance Patrick Steinhardt
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=xmqqr0ext6us.fsf@gitster.g \
--to=gitster@pobox.com \
--cc=git@vger.kernel.org \
--cc=gitgitgadget@gmail.com \
--cc=johannes.schindelin@gmx.de \
--cc=peff@peff.net \
--cc=ps@pks.im \
--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.