25 lines
378 B
Lua
25 lines
378 B
Lua
|
-- {{{ Grab environment
|
||
|
local setmetatable = setmetatable
|
||
|
-- }}}
|
||
|
|
||
|
|
||
|
local temp = {};
|
||
|
|
||
|
-- {{{ Date widget type
|
||
|
local function worker(format, warg)
|
||
|
|
||
|
local f = io.popen("getGPUTemp.py")
|
||
|
|
||
|
temp[0] = "";
|
||
|
for line in f:lines() do
|
||
|
temp[0] = temp[0] .. line
|
||
|
end
|
||
|
|
||
|
io.close(f)
|
||
|
|
||
|
return temp
|
||
|
end
|
||
|
-- }}}
|
||
|
|
||
|
return setmetatable(temp, { __call = function(_, ...) return worker(...) end })
|