cmd = cmd .. "'" .. image:gsub("'", "") .. "' 2>/dev/null"
local fp = io.popen(cmd)
+ fp:setvbuf("no")
+
local line = fp:read()
if line == "Invalid image type" then
return false, line
else
line = fp:read()
- if line == "Performing system upgrade" then
+ if line == "Performing system upgrade..." then
return true
end
line = fp:read()
- if line == "Performing system upgrade" then
+ if line == "Performing system upgrade..." then
return true
end