diff options
Diffstat (limited to 'xmake/plugins/lua/xmake.lua')
| -rw-r--r-- | xmake/plugins/lua/xmake.lua | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/xmake/plugins/lua/xmake.lua b/xmake/plugins/lua/xmake.lua index 636ef67b8..11fce7a20 100644 --- a/xmake/plugins/lua/xmake.lua +++ b/xmake/plugins/lua/xmake.lua @@ -73,13 +73,15 @@ task("lua") break end end + local result = nil if object then -- run builtin modules (xmake lua core.xxx.xxx) - print(object(unpack(option.get("arguments") or {}))) + result = object(unpack(option.get("arguments") or {})) else -- run imported modules (xmake lua core.xxx.xxx) - print(import(script, {anonymous = true})(unpack(option.get("arguments") or {}))) + result = import(script, {anonymous = true})(unpack(option.get("arguments") or {})) end + if result ~= nil then print(result) end end else -- enter interactive mode |
