summaryrefslogtreecommitdiff
path: root/src/buildtool/file_system/git_repo.hpp
diff options
context:
space:
mode:
authorMaksim Denisov <denisov.maksim@huawei.com>2024-12-04 10:22:36 +0100
committerKlaus Aehlig <klaus.aehlig@huawei.com>2025-01-13 16:20:52 +0100
commitd10e9bbbec05e177558b351a55169b31417967a8 (patch)
treea4126448843611652c1415791f4a7c270ba20ba2 /src/buildtool/file_system/git_repo.hpp
parent594b4f72fad293f3371bbc2f125ce0ec8675f9d7 (diff)
downloadjustbuild-d10e9bbbec05e177558b351a55169b31417967a8.tar.gz
GitRepo: keep GuardedRepo unexposed and adjust the interface.
(cherry-picked from d9f39250d302152d19a0aacd76eabae7a013f1a8)
Diffstat (limited to 'src/buildtool/file_system/git_repo.hpp')
-rw-r--r--src/buildtool/file_system/git_repo.hpp5
1 files changed, 2 insertions, 3 deletions
diff --git a/src/buildtool/file_system/git_repo.hpp b/src/buildtool/file_system/git_repo.hpp
index a937dc18..2d5f4df1 100644
--- a/src/buildtool/file_system/git_repo.hpp
+++ b/src/buildtool/file_system/git_repo.hpp
@@ -351,13 +351,12 @@ class GitRepo {
/// \brief Open real repository at given location.
explicit GitRepo(std::filesystem::path const& repo_path) noexcept;
- [[nodiscard]] auto GetRepoRef() const noexcept -> GuardedRepoPtr;
+ [[nodiscard]] auto GetGitRepository() const& noexcept -> git_repository&;
[[nodiscard]] auto GetGitPath() const noexcept
-> std::filesystem::path const&;
- [[nodiscard]] auto GetGitOdb() const noexcept
- -> std::unique_ptr<git_odb, decltype(&odb_closer)> const&;
+ [[nodiscard]] auto GetGitOdb() const& noexcept -> git_odb&;
using StoreDirEntryFunc =
std::function<bool(std::filesystem::path const&, ObjectType type)>;