1
0
mirror of https://github.com/kepler155c/opus synced 2025-10-10 21:37:43 +00:00

cleanup + global clipboard

This commit is contained in:
kepler155c@gmail.com
2017-10-11 22:39:04 -04:00
parent f9221e67be
commit 3460dd68b2
6 changed files with 59 additions and 87 deletions

View File

@@ -1,37 +1,15 @@
local pullEvent = os.pullEventRaw
local redirect = term.redirect
local current = term.current
local shutdown = os.shutdown
local cos = { }
os.pullEventRaw = function(...)
local co = coroutine.running()
if not cos[co] then
cos[co] = true
error('die')
end
return pullEvent(...)
end
os.shutdown = function()
end
term.current = function()
term.redirect = function()
os.pullEventRaw = pullEvent
os.shutdown = shutdown
term.current = current
term.redirect = redirect
term.redirect(term.native())
--for co in pairs(cos) do
-- print(tostring(co) .. ' ' .. coroutine.status(co))
--end
os.run(getfenv(1), 'sys/boot/multishell.boot')
os.run(getfenv(1), 'rom/programs/shell')
end
os.pullEventRaw = function()
error('die')
end
os.shutdown = function()
os.pullEventRaw = pullEvent
os.shutdown = shutdown
os.run(getfenv(1), 'sys/boot/multishell.boot')
end
os.queueEvent('modem_message')