From 6ac0e6960a3300401340191a47c680ea3432e8f1 Mon Sep 17 00:00:00 2001 From: Klaus Aehlig Date: Tue, 2 Aug 2022 17:57:45 +0200 Subject: Make ANSI escape sequences optional --- src/buildtool/common/cli.hpp | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'src/buildtool/common/cli.hpp') diff --git a/src/buildtool/common/cli.hpp b/src/buildtool/common/cli.hpp index 46af6598..f0875aaa 100644 --- a/src/buildtool/common/cli.hpp +++ b/src/buildtool/common/cli.hpp @@ -30,6 +30,7 @@ struct CommonArguments { struct LogArguments { std::optional log_file{}; LogLevel log_limit{kDefaultLogLevel}; + bool plain_log{false}; }; /// \brief Arguments required for analysing targets. @@ -148,6 +149,9 @@ static inline auto SetupLogArguments( kLastLogLevel, kDefaultLogLevel)) ->type_name("NUM"); + app->add_flag("--plain-log", + clargs->plain_log, + "Do not use ANSI escape sequences to highlight messages."); } static inline auto SetupAnalysisArguments( -- cgit v1.2.3