summaryrefslogtreecommitdiff
path: root/xmake/actions/install/main.lua
diff options
context:
space:
mode:
authorruki <[email protected]>2022-04-14 00:23:35 +0800
committerruki <[email protected]>2022-04-14 00:23:35 +0800
commitb3d43d26103d29ce04878b74ff101d8fcb321164 (patch)
treed541925ac51319774cf69742bf705daed131d1d1 /xmake/actions/install/main.lua
parent8e4983bd55693419b6a7e6548e74e8c829acf5f3 (diff)
improve run and install
Diffstat (limited to 'xmake/actions/install/main.lua')
-rw-r--r--xmake/actions/install/main.lua13
1 files changed, 4 insertions, 9 deletions
diff --git a/xmake/actions/install/main.lua b/xmake/actions/install/main.lua
index 82534ffe0..614678cf7 100644
--- a/xmake/actions/install/main.lua
+++ b/xmake/actions/install/main.lua
@@ -21,6 +21,7 @@
-- imports
import("core.base.option")
import("core.base.task")
+import("core.project.config")
import("core.project.project")
import("core.platform.platform")
import("core.base.privilege")
@@ -63,24 +64,18 @@ end
-- main
function main()
- -- get the target name
- local targetname = option.get("target")
-
- -- config it first
- task.run("config", {target = targetname, require = "n", verbose = false})
+ -- local config first
+ config.load()
-- check targets first
+ local targetname = option.get("target")
_check_targets(targetname)
-- attempt to install directly
try
{
function ()
-
- -- install target
install(targetname or (option.get("all") and "__all" or "__def"))
-
- -- trace
cprint("${color.success}install ok!")
end,