aboutsummaryrefslogtreecommitdiff
path: root/src/libmain/shared.cc
diff options
context:
space:
mode:
Diffstat (limited to 'src/libmain/shared.cc')
-rw-r--r--src/libmain/shared.cc18
1 files changed, 7 insertions, 11 deletions
diff --git a/src/libmain/shared.cc b/src/libmain/shared.cc
index 52718c231..2247aeca4 100644
--- a/src/libmain/shared.cc
+++ b/src/libmain/shared.cc
@@ -36,7 +36,7 @@ void printGCWarning()
void printMissing(ref<Store> store, const std::vector<StorePathWithOutputs> & paths, Verbosity lvl)
{
- unsigned long long downloadSize, narSize;
+ uint64_t downloadSize, narSize;
StorePathSet willBuild, willSubstitute, unknown;
store->queryMissing(paths, willBuild, willSubstitute, unknown, downloadSize, narSize);
printMissing(store, willBuild, willSubstitute, unknown, downloadSize, narSize, lvl);
@@ -45,7 +45,7 @@ void printMissing(ref<Store> store, const std::vector<StorePathWithOutputs> & pa
void printMissing(ref<Store> store, const StorePathSet & willBuild,
const StorePathSet & willSubstitute, const StorePathSet & unknown,
- unsigned long long downloadSize, unsigned long long narSize, Verbosity lvl)
+ uint64_t downloadSize, uint64_t narSize, Verbosity lvl)
{
if (!willBuild.empty()) {
if (willBuild.size() == 1)
@@ -277,6 +277,8 @@ void printVersion(const string & programName)
#if HAVE_SODIUM
cfg.push_back("signed-caches");
#endif
+ std::cout << "System type: " << settings.thisSystem << "\n";
+ std::cout << "Additional system types: " << concatStringsSep(", ", settings.extraPlatforms.get()) << "\n";
std::cout << "Features: " << concatStringsSep(", ", cfg) << "\n";
std::cout << "System configuration file: " << settings.nixConfDir + "/nix.conf" << "\n";
std::cout << "User configuration files: " <<
@@ -384,18 +386,12 @@ RunPager::~RunPager()
}
-string showBytes(unsigned long long bytes)
-{
- return (format("%.2f MiB") % (bytes / (1024.0 * 1024.0))).str();
-}
-
-
PrintFreed::~PrintFreed()
{
if (show)
- std::cout << format("%1% store paths deleted, %2% freed\n")
- % results.paths.size()
- % showBytes(results.bytesFreed);
+ std::cout << fmt("%d store paths deleted, %s freed\n",
+ results.paths.size(),
+ showBytes(results.bytesFreed));
}
Exit::~Exit() { }