summaryrefslogtreecommitdiff
path: root/xmake/core/base/dump.lua
diff options
context:
space:
mode:
authorOpportunityLiu <[email protected]>2019-06-19 11:50:00 +0800
committerOpportunityLiu <[email protected]>2019-06-19 11:50:00 +0800
commitd093198ddcd2f0f8e511dd03e848de0378b81bfd (patch)
tree05de0ee968094e3bbdebe64234d7dc79db7bb656 /xmake/core/base/dump.lua
parentd5ad005f6c8a79af48f4c73f0ec87775ab746d0d (diff)
fix string qoute rule
Diffstat (limited to 'xmake/core/base/dump.lua')
-rw-r--r--xmake/core/base/dump.lua2
1 files changed, 1 insertions, 1 deletions
diff --git a/xmake/core/base/dump.lua b/xmake/core/base/dump.lua
index 66e0208fc..303888ff0 100644
--- a/xmake/core/base/dump.lua
+++ b/xmake/core/base/dump.lua
@@ -4,7 +4,7 @@ local table = require("base/table")
local _dump = {}
function _dump._string(str, as_key)
- local quote = (not as_key) or str:match("%s")
+ local quote = (not as_key) or (not str:match("^[a-zA-Z_][a-zA-Z0-9_]*$"))
if quote then
io.write(colors.translate("${cyan}\""))
end