Comparison

prosodyctl @ 12453:1ec4a3a61cf7

Merge 0.12->trunk
author Kim Alvefur <zash@zash.se>
date Tue, 05 Apr 2022 19:49:18 +0200
parent 12452:c475a7802169
child 12578:10bb58ad5583
child 12863:891edd1ebde6
comparison
equal deleted inserted replaced
12451:76887863a6ae 12453:1ec4a3a61cf7
113 local opts = parse_args(arg, only_help); 113 local opts = parse_args(arg, only_help);
114 if opts.help then 114 if opts.help then
115 show_usage([[list]], [[Shows installed rocks]]); 115 show_usage([[list]], [[Shows installed rocks]]);
116 return 0; 116 return 0;
117 end 117 end
118 local server = opts.server or configmanager.get("*", "plugin_server");
118 if opts.outdated then 119 if opts.outdated then
119 -- put this back for luarocks 120 -- put this back for luarocks
120 arg[1] = "--outdated"; 121 arg[1] = "--outdated";
121 end 122
122 local ret = call_luarocks("list", arg[1]); 123 if not server then
124 show_warning("There is no 'plugin_server' option in the configuration file, but this is needed for 'list --outdated' to work.");
125 return 1;
126 end
127 end
128 local ret = call_luarocks("list", arg[1], server);
123 return ret; 129 return ret;
124 end 130 end
125 131
126 function commands.adduser(arg) 132 function commands.adduser(arg)
127 local opts = parse_args(arg, only_help); 133 local opts = parse_args(arg, only_help);