From 08c53d721f0b9c6e7a931eaffbed941d0bcc6253 Mon Sep 17 00:00:00 2001 From: ruki Date: Wed, 17 May 2017 08:28:19 +0800 Subject: dump lua action return value --- xmake/plugins/lua/xmake.lua | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'xmake/plugins/lua') diff --git a/xmake/plugins/lua/xmake.lua b/xmake/plugins/lua/xmake.lua index 354477e16..77833e9a3 100644 --- a/xmake/plugins/lua/xmake.lua +++ b/xmake/plugins/lua/xmake.lua @@ -69,7 +69,12 @@ task("lua") else -- run modules (xmake lua core.xxx.xxx) - import(script)(unpack(option.get("arguments") or {})) + local result = import(script)(unpack(option.get("arguments") or {})) + if type(result) == "table" then + table.dump(table) + elseif result ~= nil then + print(result) + end end else -- enter interactive mode -- cgit v1.3.1