Use lua io.write() instead of print()

io.write() gives better output control as print() is hardcoded to always
print a newline.
This commit is contained in:
Martin Lund 2024-04-27 00:48:35 +02:00
parent d8fbd607d4
commit 6e779a0520

View file

@ -22,8 +22,8 @@ if (1 == found) then
expect("Password:") expect("Password:")
send(login.password .. "\n") send(login.password .. "\n")
else else
print("\r\nDon't know login info for " .. hostname .. "\r\n") io.write("\r\nDon't know login info for " .. hostname .. "\r\n")
end end
else else
print("\r\nDidn't find a login prompt\r\n") io.write("\r\nDidn't find a login prompt\r\n")
end end