diff options
| author | ruki <[email protected]> | 2016-05-31 15:49:37 +0800 |
|---|---|---|
| committer | ruki <[email protected]> | 2016-05-31 15:49:37 +0800 |
| commit | 5769dba5932aad3a97c8db36c80a15064b71f556 (patch) | |
| tree | cd08ffc12af5dc735fd1714adcaa2657e4b0f730 /xmake/core/project/cache.lua | |
| parent | 2258b6be79c6b07a197ca27f79c89baaf8fd3779 (diff) | |
add history
Diffstat (limited to 'xmake/core/project/cache.lua')
| -rw-r--r-- | xmake/core/project/cache.lua | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/xmake/core/project/cache.lua b/xmake/core/project/cache.lua index 5ea212dfc..1a81ee4dc 100644 --- a/xmake/core/project/cache.lua +++ b/xmake/core/project/cache.lua @@ -54,6 +54,11 @@ function cache._instance(scopename) -- init instance local instance = table.inherit(cache) + -- check scopename + if not scopename:find("local%.") and not scopename:find("global%.") then + os.raise("invalid cache scope: %s", scopename) + end + -- make the cache path local cachepath = (scopename:gsub("%.", "/")) cachepath = (cachepath:gsub("^local%/", path.join(config.directory(), "cache") .. "/")) |
