summaryrefslogtreecommitdiff
path: root/xmake/actions/config/menuconf.lua
diff options
context:
space:
mode:
authorruki <[email protected]>2018-02-01 23:08:56 +0800
committerruki <[email protected]>2018-02-01 12:53:37 +0800
commit0ee92c0da0bfd6d9215622fedbd321aabf87f061 (patch)
tree83a9ed0884a1cbc8c06b81215e0eef1da0bcea4f /xmake/actions/config/menuconf.lua
parent251cb9f992863cf53cf502c2e31126fba1e58432 (diff)
improve description for menuconf
Diffstat (limited to 'xmake/actions/config/menuconf.lua')
-rw-r--r--xmake/actions/config/menuconf.lua16
1 files changed, 15 insertions, 1 deletions
diff --git a/xmake/actions/config/menuconf.lua b/xmake/actions/config/menuconf.lua
index 0fe0be4f1..19c1bb840 100644
--- a/xmake/actions/config/menuconf.lua
+++ b/xmake/actions/config/menuconf.lua
@@ -198,7 +198,21 @@ function app:_basic_configs(cache)
-- make configs by category
self._BASIC_CONFIGS = self:_make_configs_by_category(options_by_category, function (opt)
- return {name = opt[2] or opt[1], kind = (opt[3] == "k") and "boolean" or "string", default = opt[4], description = opt[5]}
+ local description = {}
+ for i = 5, 64 do
+ local desc = opt[i]
+ if type(desc) == "function" then
+ desc = desc()
+ end
+ if type(desc) == "string" then
+ table.insert(description, desc)
+ elseif type(desc) == "table" then
+ table.join2(description, desc)
+ else
+ break
+ end
+ end
+ return {name = opt[2] or opt[1], kind = (opt[3] == "k") and "boolean" or "string", default = opt[4], description = description}
end)
return self._BASIC_CONFIGS
end