From: Okhuomon Ajayi <okhuomonajayi54@gmail.com>
To: git@vger.kernel.org
Cc: gitster@pobox.com, christian.couder@gmail.com,
usmanakinyemi202@gmail.com, siddharthasthana31@gmail.com,
kaartic.sivaraam@gmail.com,
Okhuomon Ajayi <okhuomonajayi54@gmail.com>
Subject: [Outreachy PATCH v3 0/2] checkout: make unique_tracking_name() use the given repository
Date: Fri, 23 Oct 2026 22:15:31 +0100 [thread overview]
Message-ID: <20261023211533.73433-1-okhuomonajayi54@gmail.com> (raw)
In-Reply-To: <20261022105641.68963-1-okhuomonajayi54@gmail.com>
unique_tracking_name() takes a repository since v2, but it still
went through the remotes with for_each_remote(), which only works
with the_repository. As Junio pointed out, that gave the illusion
that callers could pass any repository.
Patch 1 adds repo_for_each_remote(), which takes a repository, and
keeps for_each_remote() as a wrapper that passes the_repository.
Patch 2 is v2 with unique_tracking_name() using
repo_for_each_remote(), so everything it reads comes from the given
repository.
Changes since v2:
- New patch 1 adding repo_for_each_remote().
- unique_tracking_name() now uses it instead of for_each_remote().
- Dropped the sentence about for_each_remote() from the commit
message of patch 2.
Okhuomon Ajayi (2):
remote: add repo_for_each_remote()
checkout: pass the repository to unique_tracking_name()
builtin/checkout.c | 3 ++-
builtin/worktree.c | 6 ++++--
checkout.c | 13 +++++++------
checkout.h | 4 +++-
remote.c | 14 ++++++++++----
remote.h | 2 ++
6 files changed, 28 insertions(+), 14 deletions(-)
base-commit: c51408889c3b372814bc20b9431c3b74d0d268eb
--
2.56.0
next prev parent reply other threads:[~2026-10-23 21:15 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-10-17 22:53 [Outreachy PATCH] checkout: use repository parameter in unique_tracking_name Okhuomon Ajayi
2026-10-22 9:41 ` Usman Akinyemi
2026-10-22 10:26 ` Okhuomon Ajayi
2026-10-22 10:56 ` [Outreachy PATCH v2] checkout: pass the repository to unique_tracking_name() Okhuomon Ajayi
2026-10-22 18:51 ` Junio C Hamano
2026-10-22 19:30 ` Junio C Hamano
2026-10-22 21:23 ` Okhuomon Ajayi
2026-10-23 21:15 ` Okhuomon Ajayi [this message]
2026-10-23 21:15 ` [Outreachy PATCH v3 1/2] remote: add repo_for_each_remote() Okhuomon Ajayi
2026-10-23 21:15 ` [Outreachy PATCH v3 2/2] checkout: pass the repository to unique_tracking_name() Okhuomon Ajayi
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=20261023211533.73433-1-okhuomonajayi54@gmail.com \
--to=okhuomonajayi54@gmail.com \
--cc=christian.couder@gmail.com \
--cc=git@vger.kernel.org \
--cc=gitster@pobox.com \
--cc=kaartic.sivaraam@gmail.com \
--cc=siddharthasthana31@gmail.com \
--cc=usmanakinyemi202@gmail.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox