diff options
| author | ruki <[email protected]> | 2020-12-19 00:33:58 +0800 |
|---|---|---|
| committer | ruki <[email protected]> | 2020-12-19 00:33:58 +0800 |
| commit | bbf9e7988955d4385639ee30f5df309ff6891736 (patch) | |
| tree | cdd10d7f651bc6834c36b9874c7ce8c04b851c62 /xmake/core/base | |
| parent | 37d4120c6cfd0454b45d606d2969e41631cc1f42 (diff) | |
add global cache directory
Diffstat (limited to 'xmake/core/base')
| -rw-r--r-- | xmake/core/base/global.lua | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/xmake/core/base/global.lua b/xmake/core/base/global.lua index d493235d1..61d9d9e3b 100644 --- a/xmake/core/base/global.lua +++ b/xmake/core/base/global.lua @@ -110,6 +110,11 @@ function global.directory() return global._DIRECTORY end +-- get the global cache directory +function global.cachedir() + return global.get("cachedir") or path.join(global.directory(), "cache") +end + -- load the global configuration function global.load() |
