Skip to content

Commit 53e4c04

Browse files
committed
整理日志
1 parent 8d8cdd3 commit 53e4c04

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

luci-app-easytier/luasrc/controller/easytier.lua

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,7 @@ function get_log()
8787
local files = {"/tmp/easytier.log"}
8888
for i, file in ipairs(files) do
8989
if luci.sys.call("[ -f '" .. file .. "' ]") == 0 then
90-
log = log .. luci.sys.exec("cat " .. file)
90+
log = log .. luci.sys.exec("sed 's/\\x1b\\[[0-9;]*m//g' " .. file)
9191
end
9292
end
9393
luci.http.write(log)
@@ -102,7 +102,7 @@ function get_wlog()
102102
local files = {"/tmp/easytierweb.log"}
103103
for i, file in ipairs(files) do
104104
if luci.sys.call("[ -f '" .. file .. "' ]") == 0 then
105-
log = log .. luci.sys.exec("cat " .. file)
105+
log = log .. luci.sys.exec("sed 's/\\x1b\\[[0-9;]*m//g' " .. file)
106106
end
107107
end
108108
luci.http.write(log)

0 commit comments

Comments
 (0)