diff options
-rw-r--r-- | src/luarocks/core/cfg.lua | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/luarocks/core/cfg.lua b/src/luarocks/core/cfg.lua index bbcc72ac..f93e67a7 100644 --- a/src/luarocks/core/cfg.lua +++ b/src/luarocks/core/cfg.lua | |||
@@ -49,6 +49,9 @@ local platform_order = { | |||
49 | 49 | ||
50 | local function detect_sysconfdir(lua_version) | 50 | local function detect_sysconfdir(lua_version) |
51 | local src = debug.getinfo(1, "S").source:gsub("\\", "/"):gsub("/+", "/") | 51 | local src = debug.getinfo(1, "S").source:gsub("\\", "/"):gsub("/+", "/") |
52 | if src:sub(1, 1) == "@" then | ||
53 | src = src:sub(2) | ||
54 | end | ||
52 | local basedir = src:match("^(.*)/luarocks/core/cfg.lua$") | 55 | local basedir = src:match("^(.*)/luarocks/core/cfg.lua$") |
53 | if not basedir then | 56 | if not basedir then |
54 | return | 57 | return |