1
0
mirror of https://github.com/kepler155c/opus synced 2025-11-26 20:05:14 +00:00

network group wip + virtual dirs + better trust

This commit is contained in:
kepler155c@gmail.com
2019-04-08 09:30:47 -04:00
parent 9413785248
commit 70733ab4f2
8 changed files with 92 additions and 31 deletions

View File

@@ -24,10 +24,21 @@ if multishell then
multishell.setTitle(multishell.getCurrent(), 'Telnet ' .. remoteId)
end
local socket, msg = Socket.connect(remoteId, 23)
local socket, msg, reason
if not socket then
error(msg)
while true do
socket, msg, reason = Socket.connect(remoteId, 23)
if socket then
break
elseif reason ~= 'NOTRUST' then
error(msg)
end
local s, m = shell.run('trust ' .. remoteId)
if not s then
error(m)
end
end
local ct = Util.shallowCopy(term.current())