From b2204739c6edcd77a08cfaa48d5ade4e115332a1 Mon Sep 17 00:00:00 2001 From: Thijs Schreijer Date: Mon, 23 Dec 2013 23:37:36 +0100 Subject: normalize paths in help output --- src/luarocks/help.lua | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/src/luarocks/help.lua b/src/luarocks/help.lua index 33c684ad..2774dc41 100644 --- a/src/luarocks/help.lua +++ b/src/luarocks/help.lua @@ -8,6 +8,7 @@ module("luarocks.help", package.seeall) local util = require("luarocks.util") local cfg = require("luarocks.cfg") +local dir = require("luarocks.dir") local program = util.this_program("luarocks") @@ -81,19 +82,20 @@ function run(...) end print_section("CONFIGURATION") util.printout("\tLua version: " .. cfg.lua_version) - util.printout("\tSystem configuration file: ".. sys_file .. " (" .. get_status(sys_ok) ..")") + util.printout("\tConfiguration files:") + util.printout("\t\tSystem: ".. dir.normalize(sys_file) .. " (" .. get_status(sys_ok) ..")") if home_file then - util.printout("\tUser configuration file: ".. home_file .. " (" .. get_status(home_ok) ..")\n") + util.printout("\t\tUser : ".. dir.normalize(home_file) .. " (" .. get_status(home_ok) ..")\n") else - util.printout("\tUser configuration file disabled in this LuaRocks installation.\n") + util.printout("\t\tUser : disabled in this LuaRocks installation.\n") end util.printout("\tRocks trees in use: ") for _, tree in ipairs(cfg.rocks_trees) do if type(tree) == "string" then - util.printout("\t\t"..tree) + util.printout("\t\t"..dir.normalize(tree)) else local name = tree.name and " (\""..tree.name.."\")" or "" - util.printout("\t\t"..tree.root..name) + util.printout("\t\t"..dir.normalize(tree.root)..name) end end else -- cgit v1.2.3-55-g6feb