From 218e2711e1afacd334ce50b37b0fa2d2db573e8e Mon Sep 17 00:00:00 2001 From: ruki Date: Wed, 20 Sep 2017 22:36:46 +0800 Subject: add some install scripts for package manager --- xmake/actions/require/install.lua | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'xmake/actions/require/install.lua') diff --git a/xmake/actions/require/install.lua b/xmake/actions/require/install.lua index 6d16de732..764745c33 100644 --- a/xmake/actions/require/install.lua +++ b/xmake/actions/require/install.lua @@ -26,7 +26,7 @@ import("core.base.option") import("core.base.task") import("core.project.project") -import("detect.tools.find_git") +import("lib.detect.find_tool") import("action") import("package") import("repository") @@ -114,7 +114,7 @@ function _install_packages(requires) -- -- attempt to install git from the builtin-packages first if git not found -- - if find_git() and not repository.pulled() then + if find_tool("git") and not repository.pulled() then task.run("repo", {update = true}) end @@ -192,7 +192,7 @@ function main(requires) environment.enter() -- git not found? install it first - if not find_git() then + if not find_tool("git") then _install_packages("git") end -- cgit v1.3.1