Skip to content

repository object

Brandon Williams git 4 versions – In review

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v4 Latest20 patches 6 repliesIn review
  2. v320 patches 23 repliesSuperseded
  3. v232 patches 16 repliesSuperseded
Earlier versions · 1
VersionPostedPatchesRepliesStatus
v131 patches21 repliesSuperseded

Changes in v4 from the cover letter

* Patch 11 is slightly different and turns off all path relocation when a worktree is provided instead of just for the index file (Thanks for the help Jonathan Nieder).
* 'repo_init()' has a tighter API and now requires that the provided gitdir is a path to the gitdir instead of either a path to the gitdir or path to the worktree (which has a .git file or directory) (Thanks Jonathan Tan).
* Minor comment and commit message chagnes

Patches in v4 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/20setup: don't perform lazy initialization of repository statecache.h environment.c setup.c+24 -90 replies
2/20setup: add comment indicating a hacksetup.c+6 -00 replies
3/20environment: remove namespace_len variableenvironment.c+4 -50 replies
4/20repository: introduce the repository objectMakefile repository.c repository.h+224 -00 replies
5/20environment: place key repository state in the_repositorycache.h environment.c path.c +1 more+34 -530 replies
6/20environment: store worktree in the_repositoryenvironment.c+4 -50 replies
7/20path: create path.hcache.h path.c path.h+64 -580 replies
8/20path: always pass in commondir to update_common_dirpath.c+1 -30 replies
9/20path: convert strbuf_git_common_path to take a 'struct repository'path.c path.h worktree.c+16 -80 replies
10/20path: convert do_git_path to take a 'struct repository'path.c+28 -140 replies
11/20path: worktree_git_path() should not use file relocationpath.c+2 -10 replies
12/20path: add repo_git_path and strbuf_repo_git_pathpath.c path.h+29 -00 replies
13/20path: add repo_worktree_path and strbuf_repo_worktree_pathpath.c path.h+49 -00 replies
14/20config: read config from a repository objectconfig.c config.h repository.c +1 more+183 -740 replies
15/20repository: add index_state to struct reporepository.c repository.h+25 -03 replies
16/20submodule-config: store the_submodule_cache in the_repositoryrepository.c repository.h submodule-config.c +1 more+72 -180 replies
17/20submodule: add repo_read_gitmodulessubmodule.c submodule.h+17 -00 replies
18/20submodule: convert is_submodule_initialized to work on a repositorybuiltin/grep.c builtin/submodule--helper.c submodule.c +1 more+16 -180 replies
19/20repository: enable initialization of submodulesrepository.c repository.h+64 -00 replies
20/20ls-files: use repository objectbuiltin/ls-files.c git.c t/t3007-ls-files-recurse-submodules.sh+118 -1150 replies

Reviews trailers per patch

None of the 20 patches has a Reviewed-by or Acked-by of their own; the series has one for all of them.

PatchStefan Beller
SeriesR-b
1/20
2/20
3/20
4/20
5/20
6/20
7/20
8/20
9/20
10/20
11/20
12/20
13/20
14/20
15/20
16/20
17/20
18/20
19/20
20/20

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v4 thread

Cover letter [PATCH v4 00/20] repository object

As before you can find this series at:
https://github.com/bmwill/git/tree/repository-object

Changes in v4:

* Patch 11 is slightly different and turns off all path relocation when a worktree is provided instead of just for the index file (Thanks for the help Jonathan Nieder).
* 'repo_init()' has a tighter API and now requires that the provided gitdir is a path to the gitdir instead of either a path to the gitdir or path to the worktree (which has a .git file or directory) (Thanks Jonathan Tan).
* Minor comment and commit message chagnes

Note: Like v3 this series is dependent on on 'bw/config-h' and
'bw/ls-files-sans-the-index'

Brandon Williams (20):
setup: don't perform lazy initialization of repository state
setup: add comment indicating a hack
environment: remove namespace_len variable
repository: introduce the repository object
environment: place key repository state in the_repository
environment: store worktree in the_repository
path: create path.h
path: always pass in commondir to update_common_dir
path: convert strbuf_git_common_path to take a 'struct repository'
path: convert do_git_path to take a 'struct repository'
path: worktree_git_path() should not use file relocation
path: add repo_git_path and strbuf_repo_git_path
path: add repo_worktree_path and strbuf_repo_worktree_path
config: read config from a repository object
repository: add index_state to struct repo
submodule-config: store the_submodule_cache in the_repository
submodule: add repo_read_gitmodules
submodule: convert is_submodule_initialized to work on a repository
repository: enable initialization of submodules
ls-files: use repository object

 Makefile                               |   1 +
 builtin/grep.c                         |   3 +-
 builtin/ls-files.c                     | 192 +++++++++++---------------
 builtin/submodule--helper.c            |   9 +-
 cache.h                                |  62 +--------
 config.c                               | 216 +++++++++++++++++++----------
 config.h                               |  24 ++++
 environment.c                          |  91 ++++---------
 git.c                                  |   2 +-
 path.c                                 | 130 ++++++++++++++----
 path.h                                 |  82 +++++++++++
 repository.c                           | 242 +++++++++++++++++++++++++++++++++
 repository.h                           |  97 +++++++++++++
 setup.c                                |  33 +++++
 submodule-config.c                     |  70 +++++++---
 submodule-config.h                     |  10 ++
 submodule.c                            |  35 +++--
 submodule.h                            |   4 +-
 t/t3007-ls-files-recurse-submodules.sh |  39 ++++++
 worktree.c                             |   3 +-
 20 files changed, 972 insertions(+), 373 deletions(-)
 create mode 100644 path.h
 create mode 100644 repository.c
 create mode 100644 repository.h
Signature · 1 line
2.13.1.704.gde00cce3c-goog