diff options
Diffstat (limited to 'xmake/modules/detect/tool/find_sudo.lua')
| -rw-r--r-- | xmake/modules/detect/tool/find_sudo.lua | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/xmake/modules/detect/tool/find_sudo.lua b/xmake/modules/detect/tool/find_sudo.lua index 3d0082b17..3306f2fd3 100644 --- a/xmake/modules/detect/tool/find_sudo.lua +++ b/xmake/modules/detect/tool/find_sudo.lua @@ -40,9 +40,12 @@ import("lib.detect.find_programver") -- @endcode -- function main(opt) + + -- init options + opt = opt or {} -- find program - local program = find_program("sudo", {}, "-h") + local program = find_program(opt.program or "sudo", opt.pathes, opt.check or "-h") -- find program version local version = nil |
