From cb44535305f596bd757ffb58e5ae3cde6d3589fa Mon Sep 17 00:00:00 2001 From: ruki Date: Thu, 7 Dec 2017 22:46:25 +0800 Subject: improve log and add color attrs for curses --- xmake/core/sandbox/modules/utils.lua | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) (limited to 'xmake/core/sandbox/modules/utils.lua') diff --git a/xmake/core/sandbox/modules/utils.lua b/xmake/core/sandbox/modules/utils.lua index e86eb2c08..bbd4c74c8 100644 --- a/xmake/core/sandbox/modules/utils.lua +++ b/xmake/core/sandbox/modules/utils.lua @@ -60,7 +60,7 @@ function sandbox_utils._print(...) utils._print(unpack(args)) -- write to the log file - log.printv(unpack(args)) + log:printv(unpack(args)) end -- print format string with newline @@ -83,7 +83,7 @@ function sandbox_utils.print(format, ...) utils._print(message) -- write to the log file - log.printv(message) + log:printv(message) end, catch { @@ -110,7 +110,7 @@ function sandbox_utils.printf(format, ...) utils._iowrite(message) -- write log to the log file - log.write(message) + log:write(message) end -- print format string, the builtin variables and colors with newline @@ -123,8 +123,8 @@ function sandbox_utils.cprint(format, ...) utils._print(colors.translate(message)) -- write log to the log file - if log.file() then - log.printv(colors.ignore(message)) + if log:file() then + log:printv(colors.ignore(message)) end end @@ -138,8 +138,8 @@ function sandbox_utils.cprintf(format, ...) utils._iowrite(colors.translate(message)) -- write log to the log file - if log.file() then - log.write(colors.ignore(message)) + if log:file() then + log:write(colors.ignore(message)) end end -- cgit v1.3.1