Replies: 1 comment
-
This is an equal behaviour like c-lua does. Relative paths are not allowed. You need your own require implementation to achieve this. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Hello,
I would like to reuse a Lua library for some Lua files.
But I can't do that with the relative path.
I load the "main" Lua e.g. from here.
C:\Users\admin\source\repos\EcuDiagSim\LuaSimFileStore\LuaFilesToShowTechniques\PCM_IncludeLib.lua
the library is here
C:\Users\admin\source\repos\EcuDiagSim\LuaSimFileStore\LuaLib\Conversion.lua
Inside PCM_IncludeLib.lua i try with "require" to load Conversion.lua relative.
like this
local conv = require ("\..\LuaLib\Conversion")
or
local conv = require ("..\LuaLib\Conversion")
but the lib is not found... what am I doing wrong?
Beta Was this translation helpful? Give feedback.
All reactions