diff options
| author | ruki <[email protected]> | 2023-02-08 22:55:20 +0800 |
|---|---|---|
| committer | ruki <[email protected]> | 2023-02-08 22:55:20 +0800 |
| commit | f38629bf5c5748719a02fae9afebd7ce83a64d0a (patch) | |
| tree | 305136458ff6a803889c2900f284cd528ea6e75a /xmake/core/main.lua | |
| parent | 9d8d0b6b038d831be197dea90271ae4bd1b7ea55 (diff) | |
add external workdir
Diffstat (limited to 'xmake/core/main.lua')
| -rw-r--r-- | xmake/core/main.lua | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/xmake/core/main.lua b/xmake/core/main.lua index 4e061f45d..e6c3fbfd5 100644 --- a/xmake/core/main.lua +++ b/xmake/core/main.lua @@ -139,7 +139,7 @@ function main._init() local opt_projectdir, opt_projectfile = options.project, options.file -- init the project directory - local projectdir = opt_projectdir or xmake._PROJECT_DIR + local projectdir = opt_projectdir or localcache.get("project", "projectdir") or xmake._PROJECT_DIR if projectdir and not path.is_absolute(projectdir) then projectdir = path.absolute(projectdir) elseif projectdir then @@ -149,7 +149,7 @@ function main._init() assert(projectdir) -- init the xmake.lua file path - local projectfile = opt_projectfile or xmake._PROJECT_FILE + local projectfile = opt_projectfile or localcache.get("project", "projectfile") or xmake._PROJECT_FILE if projectfile and not path.is_absolute(projectfile) then projectfile = path.absolute(projectfile, projectdir) end |
