Build/Utilities/userRequire.lua
2021-11-21 17:23:31 +00:00

19 lines
381 B
Lua

function auUserRequire(path)
local script = "./" .. path
if (not script:ends(".lua")) then
script = script .. ".lua"
end
if (os.isfile(script)) then
return auRequireAbs(script)
end
script = auGetSetting("sAbsRepoScripts") .. path
if (os.isfile(script)) then
return auRequireAbs(script)
end
return nil
end