simple fix to #20

This commit is contained in:
luke bonham 2014-01-21 16:01:28 +01:00
parent cbb144a79e
commit 3a387e9f49
1 changed files with 2 additions and 1 deletions

View File

@ -22,12 +22,13 @@ local temp = {}
local function worker(args)
local args = args or {}
local timeout = args.timeout or 5
local tempfile = args.tempfile or "/sys/class/thermal/thermal_zone0/temp"
local settings = args.settings or function() end
temp.widget = wibox.widget.textbox('')
function update()
local f = io.open("/sys/class/thermal/thermal_zone0/temp")
local f = io.open(tempfile)
if f ~= nil
then
coretemp_now = tonumber(f:read("*all")) / 1000