diff options
-rw-r--r-- | spec/util/test_env.lua | 1 | ||||
-rw-r--r-- | src/luarocks/cmd.lua | 2 |
2 files changed, 3 insertions, 0 deletions
diff --git a/spec/util/test_env.lua b/spec/util/test_env.lua index 1d4e98d8..269a1cfc 100644 --- a/spec/util/test_env.lua +++ b/spec/util/test_env.lua | |||
@@ -839,6 +839,7 @@ function test_env.main() | |||
839 | end | 839 | end |
840 | 840 | ||
841 | lfs.mkdir(testing_paths.testrun_dir) | 841 | lfs.mkdir(testing_paths.testrun_dir) |
842 | test_env.write_file(testing_paths.testrun_dir .. "/.luarocks-no-project", "") | ||
842 | lfs.mkdir(testing_paths.testing_cache) | 843 | lfs.mkdir(testing_paths.testing_cache) |
843 | lfs.mkdir(testing_paths.luarocks_tmp) | 844 | lfs.mkdir(testing_paths.luarocks_tmp) |
844 | 845 | ||
diff --git a/src/luarocks/cmd.lua b/src/luarocks/cmd.lua index 70d93670..6ce9a8b5 100644 --- a/src/luarocks/cmd.lua +++ b/src/luarocks/cmd.lua | |||
@@ -175,6 +175,8 @@ do | |||
175 | if fs.is_dir(abs .. "/.luarocks") and fs.is_dir(abs .. "/lua_modules") then | 175 | if fs.is_dir(abs .. "/.luarocks") and fs.is_dir(abs .. "/lua_modules") then |
176 | abs = abs:gsub("/.$", "") | 176 | abs = abs:gsub("/.$", "") |
177 | return abs, abs .. "/lua_modules" | 177 | return abs, abs .. "/lua_modules" |
178 | elseif fs.exists(abs .. "/.luarocks-no-project") then | ||
179 | return nil | ||
178 | end | 180 | end |
179 | try = try .. "/.." | 181 | try = try .. "/.." |
180 | end | 182 | end |