summaryrefslogtreecommitdiff
path: root/src/buildtool/file_system/git_repo.hpp
diff options
context:
space:
mode:
authorPaul Cristian Sarbu <paul.cristian.sarbu@huawei.com>2024-08-12 15:46:39 +0200
committerPaul Cristian Sarbu <paul.cristian.sarbu@huawei.com>2024-08-26 11:36:34 +0200
commitd7f6ca59d2e2713efe40c96e2c6522f6d86180d2 (patch)
treeb133c4cb743f54e621f621ee4e3db687e12f429e /src/buildtool/file_system/git_repo.hpp
parent6f4613243d8a8851aeb93cd933bd69fdec8b04c7 (diff)
downloadjustbuild-d7f6ca59d2e2713efe40c96e2c6522f6d86180d2.tar.gz
GitRepo: Create trees by directly writing to object database
The libgit2 treebuilder has unnecessary validity checks for tree entries, including for Git-specific magic names (such as '.git'), which cannot be disabled. However, in our tool any filesystem entry should be allowed to be part of a tree. Therefore, the treebuilder-based implementation for CreateTree is replaced by a direct writing of trees, by content, into the underlying repository object database. Additionally, as direct insertion into the object dabase does not check the validity of the tree entries, as was done implicitly by the treebuilder before, add a check for existence of the tree entries into the debug-level generic validity check, with the option to not perform it for ReadTree (as it is unnecessary there).
Diffstat (limited to 'src/buildtool/file_system/git_repo.hpp')
0 files changed, 0 insertions, 0 deletions