diff options
author | Jo?o Duarte <jvsDuarte08@gmail.com> | 2019-07-31 05:47:36 -0700 |
---|---|---|
committer | Jo?o Duarte <jvsDuarte08@gmail.com> | 2019-07-31 05:47:36 -0700 |
commit | a9dae0f388d61f07408f19eb556e54be473ca2ad (patch) | |
tree | 46630d4674338d52b21ea27ba4d5ff6976bfb9e3 /prosodyctl | |
parent | 1a3637b9ce9396b849e27d92cd6bda654493d817 (diff) | |
download | prosody-a9dae0f388d61f07408f19eb556e54be473ca2ad.tar.gz prosody-a9dae0f388d61f07408f19eb556e54be473ca2ad.zip |
prosodyctl: Swapped prints for the show_message function at the install/remove commands
Diffstat (limited to 'prosodyctl')
-rwxr-xr-x | prosodyctl | 9 |
1 files changed, 4 insertions, 5 deletions
@@ -95,12 +95,12 @@ function commands.install(arg) local flag = "--tree=" if arg[1] and arg[1]:sub(1, #flag) == flag then local dir = arg[1]:match("=(.+)$") - print("Installing module "..arg[2].." at "..dir) + show_message("Installing module %s at %s", arg[2], dir) os.execute("luarocks --tree='"..dir.."' --server='http://localhost/' install "..arg[2]) show_module_configuration_help(arg[2]); return 0; else - print("Installing module "..arg[1].." at "..installer_plugin_path) + show_message("Installing module %s at %s", arg[1], installer_plugin_path) -- I've build a local server to upload some new rockspecs, like mod_smacks'. We can replace this server by one from -- prosody's, where we can oficially disbrute rocks/rockspecs for all modules os.execute("luarocks --tree='"..installer_plugin_path.."' --server='http://localhost/' install "..arg[1]) @@ -120,13 +120,12 @@ function commands.remove(arg) -- I'm considering this optional flag comes first if arg[1] and arg[1]:sub(1, #flag) == flag then local dir = arg[1]:match("=(.+)$") - print("Removing module "..arg[2].." at "..dir) + show_message("Removing module %s at %s", arg[2], dir) os.execute("luarocks remove --tree='"..dir.."' "..arg[2]) return 0; else - print("Removing "..arg[1].." from "..installer_plugin_path) + show_message("Removing %s from %s", arg[1], installer_plugin_path) os.execute("luarocks --tree='"..installer_plugin_path.."' remove "..arg[1]) - print("Done!") return 0; end end |