From: "Theodore Ts'o" <tytso@mit.edu>
To: Junio C Hamano <gitster@pobox.com>
Cc: "Torsten Bögershausen" <tboegi@web.de>,
"Chris Packham" <judge.packham@gmail.com>,
GIT <git@vger.kernel.org>
Subject: Re: Testing for existence of a remote branch from a script
Date: Mon, 6 Jan 2025 11:36:36 -0500 [thread overview]
Message-ID: <20250106163636.GH1284777@mit.edu> (raw)
In-Reply-To: <xmqqsepw0xk7.fsf@gitster.g>
On Mon, Jan 06, 2025 at 07:30:32AM -0800, Junio C Hamano wrote:
> - Would it be useful if we introduced the ability to advertise
> "custom capabilities" from the receiving end of the connection,
> that does not affect how the rest of Git behaves at all?
So if enhancing the git server's functionality (either via git
ls-remotes or some other operation) is on the table, one of the things
that I would really love is some way of asking the question is "git
commit <SHA hash>" in the remote repository reachable via some branch
or git tag?", and optionally, "which git branch/tag should be fetched
if the testing infrastructure wants to be able to test that specific
git commit ID?"
I could solve that problem by doing a "git fetch", but in my case, the
specific repository in question might not even be on the local client
where the user is executing "gce-xfstests -c ext4/4k -g auto --repo
stable-rc.git --commit 47c2f92131c4". (This command launches a VM
which actually builds the kernel, and I'd like to be able to give
immediate feedback about whether the command will fail due to the user
typo'ing the git commit id without either waiting for the Google Cloud
VM to launch and then fail, or doing a "git fetch" and determining
whether the git commit is there. I might be executing this command
while on a very slow networking link, such as when I'm in an airplane
or on a cruise ship, and so the cost of doing the "git fetch" might be
prohibitive.)
Thanks,
- Ted
next prev parent reply other threads:[~2025-01-06 16:36 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-01-06 4:40 Testing for existence of a remote branch from a script Chris Packham
2025-01-06 6:51 ` Torsten Bögershausen
2025-01-06 15:30 ` Junio C Hamano
2025-01-06 16:36 ` Theodore Ts'o [this message]
2025-01-06 18:44 ` Junio C Hamano
2025-01-06 20:50 ` Chris Packham
2025-01-06 15:05 ` Theodore Ts'o
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=20250106163636.GH1284777@mit.edu \
--to=tytso@mit.edu \
--cc=git@vger.kernel.org \
--cc=gitster@pobox.com \
--cc=judge.packham@gmail.com \
--cc=tboegi@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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).