Software /
code /
prosody
Comparison
util/prosodyctl.lua @ 11298:79466cc86041
util.prosodyctl: Rename unused variable to '_' [luacheck]
author | Kim Alvefur <zash@zash.se> |
---|---|
date | Thu, 21 Jan 2021 19:17:31 +0100 |
parent | 11296:06bb0cdef50b |
child | 11299:abe8cd8fad14 |
comparison
equal
deleted
inserted
replaced
11297:2e9d4c517919 | 11298:79466cc86041 |
---|---|
219 | 219 |
220 local render_cli = interpolation.new("%b{}", function (s) return "'"..s:gsub("'","'\\''").."'" end) | 220 local render_cli = interpolation.new("%b{}", function (s) return "'"..s:gsub("'","'\\''").."'" end) |
221 | 221 |
222 local function call_luarocks(operation, mod, server) | 222 local function call_luarocks(operation, mod, server) |
223 local dir = prosody.paths.installer; | 223 local dir = prosody.paths.installer; |
224 local ok, where, code = os.execute(render_cli("luarocks {op} --tree={dir} {server&--server={server}} {mod?}", { | 224 local ok, _, code = os.execute(render_cli("luarocks {op} --tree={dir} {server&--server={server}} {mod?}", { |
225 dir = dir; op = operation; mod = mod; server = server; | 225 dir = dir; op = operation; mod = mod; server = server; |
226 })); | 226 })); |
227 if type(ok) == "number" then ok, code = ok == 0, ok; end | 227 if type(ok) == "number" then ok, code = ok == 0, ok; end |
228 return code; | 228 return code; |
229 end | 229 end |