From 6fc92e343d6ea1db91bcb6c8e471b2442a8b5f43 Mon Sep 17 00:00:00 2001 From: Paul Ouellette Date: Wed, 19 Jun 2019 21:28:10 -0400 Subject: Misc. fixes --- src/luarocks/admin/cmd/add.lua | 3 +-- src/luarocks/cmd.lua | 4 ++-- src/luarocks/cmd/config.lua | 1 - src/luarocks/cmd/new_version.lua | 2 +- 4 files changed, 4 insertions(+), 6 deletions(-) diff --git a/src/luarocks/admin/cmd/add.lua b/src/luarocks/admin/cmd/add.lua index 0682d89b..ad16c232 100644 --- a/src/luarocks/admin/cmd/add.lua +++ b/src/luarocks/admin/cmd/add.lua @@ -12,8 +12,7 @@ local cache = require("luarocks.admin.cache") local index = require("luarocks.admin.index") function add.add_to_parser(parser) - local cmd = parser:command("add", "Add a rock or rockspec to a rocks server.", - util.see_also()) + local cmd = parser:command("add", "Add a rock or rockspec to a rocks server.", util.see_also()) :add_help("--help") cmd:argument("rock", "A local rockspec or rock file.") diff --git a/src/luarocks/cmd.lua b/src/luarocks/cmd.lua index ab8d22c6..d85661d8 100644 --- a/src/luarocks/cmd.lua +++ b/src/luarocks/cmd.lua @@ -308,7 +308,7 @@ local function get_status(status) return status and "ok" or "not found" end -local function get_config_text() +local function get_config_text(cfg) local buf = "Configuration:\n Lua version: "..cfg.lua_version.."\n" if cfg.luajit_version then buf = buf.." LuaJIT version: "..cfg.luajit_version.."\n" @@ -343,7 +343,7 @@ Variables: Variables from the "variables" table of the configuration file can be overridden with VAR=VALUE assignments. -]]..get_config_text() +]]..get_config_text(cfg) local parser = argparse( dir.base_name(program), "LuaRocks "..cfg.program_version..", the Lua package manager\n\n".. diff --git a/src/luarocks/cmd/config.lua b/src/luarocks/cmd/config.lua index fa954b3c..4f688a65 100644 --- a/src/luarocks/cmd/config.lua +++ b/src/luarocks/cmd/config.lua @@ -59,7 +59,6 @@ Query information about the LuaRocks configuration. :args("?") cmd:option("--scope", "The scope indicates which config file should be rewritten.\n".. - 'Accepted values are "system", "user" or "project".\n'.. '* Using a wrapper created with `luarocks init`, the default is "project".\n'.. '* Using --local (or when `local_by_default` is `true`), the default is "user".\n'.. '* Otherwise, the default is "system".') diff --git a/src/luarocks/cmd/new_version.lua b/src/luarocks/cmd/new_version.lua index 7c3e9329..95d762be 100644 --- a/src/luarocks/cmd/new_version.lua +++ b/src/luarocks/cmd/new_version.lua @@ -21,7 +21,7 @@ default server. If a rockspec is given, it uses it instead. If no argument is given, it looks for a rockspec same way 'luarocks make' does. If the version number is not given and tag is passed using --tag, -it is used as the version, with 'v' removed from beginnnumbering. +it is used as the version, with 'v' removed from beginning. Otherwise, it only increments the revision number of the given (or downloaded) rockspec. -- cgit v1.2.3-55-g6feb