aboutsummaryrefslogtreecommitdiff
path: root/src/libmain/loggers.cc
diff options
context:
space:
mode:
authorEelco Dolstra <edolstra@gmail.com>2020-06-29 14:37:22 +0200
committerEelco Dolstra <edolstra@gmail.com>2020-06-29 14:37:22 +0200
commitca946860ce6ce5d4800b0d93d3f83c30d3c953c0 (patch)
treeaa6511e64cec9d5216e5335849af3e87542ee1b8 /src/libmain/loggers.cc
parentbc03c6f23dbb2d5491410075f805946d4cc62ca2 (diff)
Fix bash completion
Diffstat (limited to 'src/libmain/loggers.cc')
-rw-r--r--src/libmain/loggers.cc3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/libmain/loggers.cc b/src/libmain/loggers.cc
index c44bb6408..f62e9372c 100644
--- a/src/libmain/loggers.cc
+++ b/src/libmain/loggers.cc
@@ -1,12 +1,13 @@
#include "loggers.hh"
#include "progress-bar.hh"
+#include "util.hh"
namespace nix {
LogFormat defaultLogFormat = LogFormat::raw;
LogFormat parseLogFormat(const std::string & logFormatStr) {
- if (logFormatStr == "raw")
+ if (logFormatStr == "raw" || getEnv("NIX_GET_COMPLETIONS"))
return LogFormat::raw;
else if (logFormatStr == "raw-with-logs")
return LogFormat::rawWithLogs;