diff options
author | Paul Cristian Sarbu <paul.cristian.sarbu@huawei.com> | 2023-10-31 14:50:45 +0100 |
---|---|---|
committer | Paul Cristian Sarbu <paul.cristian.sarbu@huawei.com> | 2023-11-14 13:35:01 +0100 |
commit | 6377b2e150857ccf52269a0251dfcd201f9b296f (patch) | |
tree | df1792ae74d2286acbd52b57d207b73dcb0f5065 /src | |
parent | 8ac435162ff41d8b83b2f94dec67a945b7a73b5d (diff) | |
download | justbuild-6377b2e150857ccf52269a0251dfcd201f9b296f.tar.gz |
commit_git_map fix: Fetch from correct location if fetch URL is a path
Diffstat (limited to 'src')
-rw-r--r-- | src/other_tools/root_maps/commit_git_map.cpp | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/src/other_tools/root_maps/commit_git_map.cpp b/src/other_tools/root_maps/commit_git_map.cpp index f4ee1c17..40399811 100644 --- a/src/other_tools/root_maps/commit_git_map.cpp +++ b/src/other_tools/root_maps/commit_git_map.cpp @@ -86,6 +86,7 @@ void WriteIdFileAndSetWSRoot(std::string const& root_tree_id, void EnsureCommit(GitRepoInfo const& repo_info, std::filesystem::path const& repo_root, + std::string const& fetch_repo, GitCASPtr const& git_cas, gsl::not_null<CriticalGitOpMap*> const& critical_git_op_map, gsl::not_null<ImportToGitMap*> const& import_to_git_map, @@ -361,7 +362,7 @@ void EnsureCommit(GitRepoInfo const& repo_info, fatal); }); if (not git_repo->FetchViaTmpRepo(tmp_dir->GetPath(), - repo_info.repo_url, + fetch_repo, repo_info.branch, git_bin, launcher, @@ -386,7 +387,7 @@ void EnsureCommit(GitRepoInfo const& repo_info, "{} for remote {}", repo_info.hash, repo_info.branch, - repo_info.repo_url), + fetch_repo), /*fatal=*/true); return; } @@ -534,6 +535,7 @@ auto CreateCommitGitMap( {std::move(op_key)}, [key, repo_root, + fetch_repo, critical_git_op_map, import_to_git_map, git_bin, @@ -564,6 +566,7 @@ auto CreateCommitGitMap( }); EnsureCommit(key, repo_root, + fetch_repo, op_result.git_cas, critical_git_op_map, import_to_git_map, |