summaryrefslogtreecommitdiff
path: root/src/other_tools/just_mr/main.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/other_tools/just_mr/main.cpp')
-rw-r--r--src/other_tools/just_mr/main.cpp8
1 files changed, 7 insertions, 1 deletions
diff --git a/src/other_tools/just_mr/main.cpp b/src/other_tools/just_mr/main.cpp
index 1e8905d6..47ec2633 100644
--- a/src/other_tools/just_mr/main.cpp
+++ b/src/other_tools/just_mr/main.cpp
@@ -676,7 +676,7 @@ auto main(int argc, char* argv[]) -> int {
kDefaultDistdirs);
}
- // read checkout locations
+ // read checkout locations and alternative mirrors
if (arguments.common.checkout_locations_file) {
try {
std::ifstream ifs(*arguments.common.checkout_locations_file);
@@ -685,6 +685,12 @@ auto main(int argc, char* argv[]) -> int {
checkout_locations_json
.value("checkouts", nlohmann::json::object())
.value("git", nlohmann::json::object());
+ arguments.common.alternative_mirrors->local_mirrors =
+ checkout_locations_json.value("local mirrors",
+ nlohmann::json::object());
+ arguments.common.alternative_mirrors->preferred_hostnames =
+ checkout_locations_json.value("preferred hostnames",
+ nlohmann::json::array());
} catch (std::exception const& e) {
Logger::Log(
LogLevel::Error,