diff options
author | Klaus Aehlig <klaus.aehlig@huawei.com> | 2024-01-24 09:55:31 +0100 |
---|---|---|
committer | Klaus Aehlig <klaus.aehlig@huawei.com> | 2024-01-24 18:57:50 +0100 |
commit | 617fad94f3ea4566ad4124d2a3731d633bd84b9d (patch) | |
tree | cbb038a0228f839a7262add5f2d10c98e31a2d87 /src/other_tools/root_maps/fpath_git_map.cpp | |
parent | f6c2fe3e30bc5e92e2c8134fb2135a532788bc3b (diff) | |
download | justbuild-617fad94f3ea4566ad4124d2a3731d633bd84b9d.tar.gz |
just-mr: in to_git warning, report actual tool names
... instead of some hard-coded strings, as that can be confusing
when the tool is packaged under a different name.
Diffstat (limited to 'src/other_tools/root_maps/fpath_git_map.cpp')
-rw-r--r-- | src/other_tools/root_maps/fpath_git_map.cpp | 20 |
1 files changed, 13 insertions, 7 deletions
diff --git a/src/other_tools/root_maps/fpath_git_map.cpp b/src/other_tools/root_maps/fpath_git_map.cpp index f8199547..79767b95 100644 --- a/src/other_tools/root_maps/fpath_git_map.cpp +++ b/src/other_tools/root_maps/fpath_git_map.cpp @@ -136,15 +136,19 @@ auto CreateFilePathGitMap( gsl::not_null<CriticalGitOpMap*> const& critical_git_op_map, gsl::not_null<ImportToGitMap*> const& import_to_git_map, gsl::not_null<ResolveSymlinksMap*> const& resolve_symlinks_map, - std::size_t jobs) -> FilePathGitMap { + std::size_t jobs, + std::string multi_repo_tool_name, + std::string build_tool_name) -> FilePathGitMap { auto dir_to_git = [current_subcmd, critical_git_op_map, import_to_git_map, - resolve_symlinks_map](auto ts, - auto setter, - auto logger, - auto /*unused*/, - auto const& key) { + resolve_symlinks_map, + multi_repo_tool_name, + build_tool_name](auto ts, + auto setter, + auto logger, + auto /*unused*/, + auto const& key) { // setup wrapped logger auto wrapped_logger = std::make_shared<AsyncMapConsumerLogger>( [logger](auto const& msg, bool fatal) { @@ -251,9 +255,11 @@ auto CreateFilePathGitMap( if (current_subcmd) { (*logger)(fmt::format("Inefficient Git import of file " "path \'{}\'.\nPlease consider using " - "\'just-mr setup\' and \'just {}\' " + "\'{} setup\' and \'{} {}\' " "separately to cache the output.", key.fpath.string(), + multi_repo_tool_name, + build_tool_name, *current_subcmd), /*fatal=*/false); } |