1 local pomodoro = require("widgets/pomodoro/init")
2 local wibox = require("wibox")
4 -- durations in seconds
5 pomodoro.short_pause_duration = 5 * 60
6 pomodoro.long_pause_duration = 30 * 60
7 pomodoro.work_duration = 25 * 60
10 pomodoro.format = function (t) return " <b>"..t.."</b>" end
14 pombox = wibox.layout.fixed.horizontal()
15 pombox:add(pomodoro.icon_widget)
16 pombox:add(pomodoro.widget)
18 --TODO connect signals to something sensible (sb:20170130)
19 -- pomodoro:connect_signal("stop_working", function () naughty.notify{ text = "stop_working", timeout = 10 } end)
20 -- pomodoro:connect_signal("stop_pause", function () naughty.notify{ text = "stop_pause", timeout = 10 } end)
21 -- pomodoro:connect_signal("start_working", function () naughty.notify{ text = "start_working", timeout = 10 } end)
22 pomodoro:connect_signal("start_pause", function ()
23 awful.spawn(terminal.." -name diary -e vim -c 'call vimwiki#diary#make_note(v:count1)' + -c 'r !date +\" * \\%H:\\%M \"' -c 'start!'")
26 globalkeys = awful.util.table.join(globalkeys,
27 awful.key({ modkey, "Shift" }, "p", function() pomodoro:start() end)