From fa0925e382335d01f50ea26130aedc692483b8cf Mon Sep 17 00:00:00 2001 From: Hisham Muhammad Date: Mon, 23 Jul 2018 10:51:07 -0300 Subject: cmd: report arch when crashing --- src/luarocks/cmd.lua | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) (limited to 'src') diff --git a/src/luarocks/cmd.lua b/src/luarocks/cmd.lua index 5af3dd95..1a4cd0e1 100644 --- a/src/luarocks/cmd.lua +++ b/src/luarocks/cmd.lua @@ -272,8 +272,15 @@ function cmd.run_command(description, commands, external_namespace, ...) check_popen() local function error_handler(err) + local mode = "Arch.: " .. (cfg and cfg.arch or "unknown") + if package.config:sub(1, 1) == "\\" then + if cfg and cfg.fs_use_modules then + mode = mode .. " (fs_use_modules = true)" + end + end return debug.traceback("LuaRocks "..cfg.program_version.. - " bug (please report at https://github.com/luarocks/luarocks/issues).\n"..err, 2) + " bug (please report at https://github.com/luarocks/luarocks/issues).\n".. + mode.."\n"..err, 2) end --- Display an error message and exit. -- cgit v1.2.3-55-g6feb