OC-PsychOS/exec/ps.lua

10 lines
224 B
Lua
Raw Normal View History

local tA = {...}
local f=tA[1] or ""
print("PID\tUser\tName")
for k,v in pairs(os.tasks()) do
local _,_,uid = os.taskinfo(k)
if v:find(f) then
print(tostring(k).."\t"..tostring(uid:sub(1,6)).."\t"..tostring(v))
end
end