mirror of
https://github.com/Laupetin/OpenAssetTools.git
synced 2025-12-27 12:31:50 +00:00
fix: only show console color when supported
This commit is contained in:
@@ -30,6 +30,8 @@ public:
|
||||
*/
|
||||
bool Start(const int argc, const char** argv)
|
||||
{
|
||||
con::init();
|
||||
|
||||
auto shouldContinue = true;
|
||||
if (!m_args.ParseArgs(argc, argv, shouldContinue))
|
||||
return false;
|
||||
|
||||
@@ -303,12 +303,12 @@ bool UnlinkerArgs::ParseArgs(const int argc, const char** argv, bool& shouldCont
|
||||
|
||||
// -v; --verbose
|
||||
if (m_argument_parser.IsOptionSpecified(OPTION_VERBOSE))
|
||||
con::globalLogLevel = con::LogLevel::DEBUG;
|
||||
con::set_log_level(con::LogLevel::DEBUG);
|
||||
else
|
||||
con::globalLogLevel = con::LogLevel::INFO;
|
||||
con::set_log_level(con::LogLevel::INFO);
|
||||
|
||||
// --no-color
|
||||
con::globalUseColor = !m_argument_parser.IsOptionSpecified(OPTION_NO_COLOR);
|
||||
con::set_use_color(!m_argument_parser.IsOptionSpecified(OPTION_NO_COLOR));
|
||||
|
||||
// -min; --minimal-zone
|
||||
m_minimal_zone_def = m_argument_parser.IsOptionSpecified(OPTION_MINIMAL_ZONE_FILE);
|
||||
|
||||
Reference in New Issue
Block a user