From 26f8e94b86df915a33152f35697b5446442efb1b Mon Sep 17 00:00:00 2001 From: Joel Rosdahl Date: Mon, 2 Jan 2023 20:46:25 +0100 Subject: [PATCH] feat: Consistently show cache size and max size with one decimal --- src/core/Statistics.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/core/Statistics.cpp b/src/core/Statistics.cpp index 13302fe92..e76ea5e01 100644 --- a/src/core/Statistics.cpp +++ b/src/core/Statistics.cpp @@ -1,4 +1,4 @@ -// Copyright (C) 2021-2022 Joel Rosdahl and other contributors +// Copyright (C) 2021-2023 Joel Rosdahl and other contributors // // See doc/AUTHORS.adoc for a complete list of contributors. // @@ -323,11 +323,11 @@ Statistics::format_human_readable(const Config& config, if (!from_log) { std::vector size_cells{ " Cache size (GB):", - C(FMT("{:.2f}", static_cast(local_size) / g)).right_align()}; + C(FMT("{:.1f}", static_cast(local_size) / g)).right_align()}; if (config.max_size() != 0) { size_cells.emplace_back("/"); size_cells.emplace_back( - C(FMT("{:.2f}", static_cast(config.max_size()) / g)) + C(FMT("{:.1f}", static_cast(config.max_size()) / g)) .right_align()); size_cells.emplace_back(percent(local_size, config.max_size())); } -- 2.47.2