From a19575867f1335c0c73fd90e14aed0d689cfc42e Mon Sep 17 00:00:00 2001 From: Hisham Date: Fri, 6 Jan 2017 17:44:35 -0200 Subject: Oops! Fix warning message. --- src/luarocks/command_line.lua | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'src') diff --git a/src/luarocks/command_line.lua b/src/luarocks/command_line.lua index 3f17b18a..528ca068 100644 --- a/src/luarocks/command_line.lua +++ b/src/luarocks/command_line.lua @@ -187,7 +187,9 @@ function command_line.run_command(...) util.warning("The directory '" .. cfg.local_cache .. "' or its parent directory ".. "is not owned by the current user and the cache has been disabled. ".. "Please check the permissions and owner of that directory. ".. - "If executing pip with sudo, you may want sudo's -H flag.") + (cfg.is_platform("unix") + and ("If executing "..util.this_program("luarocks").." with sudo, you may want sudo's -H flag.") + or "")) cfg.local_cache = fs.make_temp_dir("local_cache") util.schedule_function(fs.delete, cfg.local_cache) end -- cgit v1.2.3-55-g6feb