summaryrefslogtreecommitdiff
path: root/xmake/core/project/option.lua
diff options
context:
space:
mode:
authorruki <[email protected]>2021-08-01 11:02:25 +0800
committerruki <[email protected]>2021-08-01 11:02:25 +0800
commitcdf6f04361f0ff08562e62f22b3fec8367cfde2a (patch)
tree4638400787e2baca21aa68c7ed00d0745c64565a /xmake/core/project/option.lua
parent9a18e7e60531afdae14c7ed7fe846e850e1cb207 (diff)
improve to check option tips
Diffstat (limited to 'xmake/core/project/option.lua')
-rw-r--r--xmake/core/project/option.lua9
1 files changed, 8 insertions, 1 deletions
diff --git a/xmake/core/project/option.lua b/xmake/core/project/option.lua
index a92f8922f..93d25990f 100644
--- a/xmake/core/project/option.lua
+++ b/xmake/core/project/option.lua
@@ -175,7 +175,14 @@ function _instance:_check()
end
-- trace
- utils.cprint("checking for %s ... %s", name, self:enabled() and "${color.success}${text.success}" or "${color.nothing}${text.nothing}")
+ local result
+ if self:enabled() then
+ local value = self:value()
+ result = "${color.success}" .. (type(value) == "boolean" and "${text.success}" or tostring(value))
+ else
+ result = "${color.nothing}${text.nothing}"
+ end
+ utils.cprint("checking for %s ... %s", name, result)
if not ok then
os.raise(errors)
end