Changed wine test to check for .exe"$ or .EXE"$ because of quoting string paths

This commit is contained in:
Bill Ferguson
2018-03-10 13:45:04 -05:00
parent b4ea97ce37
commit 1c587d3726

View File

@@ -67,8 +67,7 @@ function dtutils_file.check_if_bin_exists(bin)
if string.len(path) > 0 then
if dtutils_file.check_if_file_exists(path) then
path = "\"" .. path .. "\""
if (string.match(path, ".exe$") or string.match(path, ".EXE%")) and
dt.configuration.running_os ~= "windows" or
if (string.match(path, ".exe\"$") or string.match(path, ".EXE\"$")) and dt.configuration.running_os ~= "windows" then
result = "wine " .. path
elseif dt.configuration.running_os == "macos" then
result = "open -a -W " .. path