working on require needs to be done before EOW

This commit is contained in:
2025-11-10 09:50:32 -05:00
parent fdb67d9afb
commit b288bb3cae
124 changed files with 9828 additions and 1 deletions

23
src/disks/45h/bin_/top Normal file
View File

@@ -0,0 +1,23 @@
local hpv=require("hypervisor")
local term=component.getFirst("screen")
term.clear()
local function m(str, m)
if #str>m then
return str:sub(1,m-1).."- "
else
while #str~=m do
str=str.." "
end
return str.." "
end
end
for i in hpv.listProc() do
term.print(m(i.name, 15)..m(i.status, 7)..m(i.pid, 4))
for _,v in ipairs(i.threads) do
if v.name~="main" then
term.print(" "..m(v.name, 12)..m(v.status, 7))
end
end
end