From 95a57f15ca795eb1b36363b7d6db6b88bfe444e2 Mon Sep 17 00:00:00 2001 From: Vincent Ambo Date: Tue, 19 May 2020 04:52:47 +0100 Subject: refactor(3p/nix/nix-*): Replace logging with glog in binaries --- third_party/nix/src/nix-copy-closure/nix-copy-closure.cc | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) (limited to 'third_party/nix/src/nix-copy-closure') diff --git a/third_party/nix/src/nix-copy-closure/nix-copy-closure.cc b/third_party/nix/src/nix-copy-closure/nix-copy-closure.cc index 3cc29ae337ff..e4ae1bb35ad6 100644 --- a/third_party/nix/src/nix-copy-closure/nix-copy-closure.cc +++ b/third_party/nix/src/nix-copy-closure/nix-copy-closure.cc @@ -1,3 +1,4 @@ +#include #include "legacy.hh" #include "shared.hh" #include "store-api.hh" @@ -21,10 +22,10 @@ static int _main(int argc, char** argv) { else if (*arg == "--version") printVersion("nix-copy-closure"); else if (*arg == "--gzip" || *arg == "--bzip2" || *arg == "--xz") { - if (*arg != "--gzip") - printMsg(lvlError, format("Warning: '%1%' is not implemented, " - "falling back to gzip") % - *arg); + if (*arg != "--gzip") { + LOG(WARNING) << "'" << *arg + << "' is not implemented, falling back to gzip"; + } gzip = true; } else if (*arg == "--from") toMode = false; @@ -33,7 +34,7 @@ static int _main(int argc, char** argv) { else if (*arg == "--include-outputs") includeOutputs = true; else if (*arg == "--show-progress") - printMsg(lvlError, "Warning: '--show-progress' is not implemented"); + LOG(WARNING) << "'--show-progress' is not implemented"; else if (*arg == "--dry-run") dryRun = true; else if (*arg == "--use-substitutes" || *arg == "-s") -- cgit 1.4.1