From: "Phillip Wood via GitGitGadget" <gitgitgadget@gmail.com>
To: git@vger.kernel.org
Cc: Han-Wen Nienhuys <hanwen@google.com>,
Phillip Wood <phillip.wood@dunelm.org.uk>
Subject: [PATCH 0/3] update delete_ref(), update_ref() and ref_exists() to take a struct repository
Date: Fri, 19 Jun 2020 15:21:07 +0000 [thread overview]
Message-ID: <pull.665.git.1592580071.gitgitgadget@gmail.com> (raw)
The code handling pseudo refs such as BISECT_HEAD or CHERRY_PICK_HEAD
assumes that they are files and uses unlink() and file_exists() on the
corresponding paths rather than using the ref api. In repositories using
reftable to store references this will not work. This patch series is a
preparatory step that updates some reference functions to take a struct
repository in preparation for converting code that handles pseudo refs to
the ref api. The conversion will be handled by a separate series
These patches could each be split in two (thereby making the individual
patches smaller) by changing the callers to pass the_repository first and
then changing the call chain to pass a struct repository around if desired.
This series is based on master - 101b3204f3 ("The third batch", 2020-06-17).
When merging into pu there are non-trivial conflicts with
jx/proc-receive-hook, dr/push-remoteref-fix and mr/bisect-in-c-2. I have
prepared a conflict resolution [1] I'm happy to rebase on top of a merge of
master and those three branches if that is helpful.
[1] tag merge-repo-refs-into-pu/v1 at https://github.com/phillipwood/git.git
Phillip Wood (3):
refs: update delete_ref() to take a struct repository
refs: update update_ref() to take a struct repository
refs: update ref_exists() to take a struct repository
bisect.c | 18 ++++++----
branch.c | 14 ++++----
branch.h | 6 ++--
builtin/am.c | 19 +++++-----
builtin/bisect--helper.c | 8 ++---
builtin/branch.c | 23 ++++++------
builtin/checkout.c | 17 +++++----
builtin/clone.c | 16 ++++-----
builtin/commit.c | 4 +--
builtin/for-each-ref.c | 4 +--
builtin/log.c | 6 ++--
builtin/ls-remote.c | 2 +-
builtin/merge.c | 12 +++----
builtin/notes.c | 15 ++++----
builtin/pull.c | 5 +--
builtin/rebase.c | 10 +++---
builtin/receive-pack.c | 2 +-
builtin/remote.c | 11 +++---
builtin/replace.c | 2 +-
builtin/reset.c | 10 +++---
builtin/revert.c | 2 +-
builtin/send-pack.c | 3 +-
builtin/stash.c | 8 ++---
builtin/symbolic-ref.c | 3 +-
builtin/tag.c | 8 ++---
builtin/update-ref.c | 5 +--
builtin/verify-tag.c | 2 +-
builtin/worktree.c | 8 ++---
diff.c | 2 +-
fast-import.c | 2 +-
notes-cache.c | 4 +--
notes-cache.h | 2 +-
notes-utils.c | 2 +-
ref-filter.c | 76 +++++++++++++++++++++++++---------------
ref-filter.h | 11 +++---
refs.c | 14 ++++----
refs.h | 6 ++--
remote.c | 30 +++++++++-------
remote.h | 13 ++++---
reset.c | 8 ++---
sequencer.c | 41 +++++++++++-----------
sequencer.h | 2 +-
sha1-name.c | 5 +--
transport-helper.c | 32 +++++++++--------
transport-internal.h | 4 ++-
transport.c | 15 ++++----
transport.h | 3 +-
wt-status.c | 41 ++++++++++++----------
wt-status.h | 2 +-
49 files changed, 314 insertions(+), 244 deletions(-)
base-commit: 101b3204f37606972b40fc17dec84560c22f69f6
Published-As: https://github.com/gitgitgadget/git/releases/tag/pr-665%2Fphillipwood%2Fwip%2Frepo-refs-v1
Fetch-It-Via: git fetch https://github.com/gitgitgadget/git pr-665/phillipwood/wip/repo-refs-v1
Pull-Request: https://github.com/gitgitgadget/git/pull/665
--
gitgitgadget
next reply other threads:[~2020-06-19 15:55 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-06-19 15:21 Phillip Wood via GitGitGadget [this message]
2020-06-19 15:21 ` [PATCH 1/3] refs: update delete_ref() to take a struct repository Phillip Wood via GitGitGadget
2020-06-19 15:21 ` [PATCH 2/3] refs: update update_ref() " Phillip Wood via GitGitGadget
2020-06-19 15:21 ` [PATCH 3/3] refs: update ref_exists() " Phillip Wood via GitGitGadget
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=pull.665.git.1592580071.gitgitgadget@gmail.com \
--to=gitgitgadget@gmail.com \
--cc=git@vger.kernel.org \
--cc=hanwen@google.com \
--cc=phillip.wood@dunelm.org.uk \
/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.