-
Notifications
You must be signed in to change notification settings - Fork 0
/
.thymerc
23 lines (20 loc) · 902 Bytes
/
.thymerc
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
set :timer, 25*60 # 25 minute pomodoros
set :timer_break, 5*60 # 5 minute breaks
set :warning, 5*60 # show warning color in tmux at <5 minutes, 0 to disable
set :break_color, 'blue' # break color is blue
set :interval, 1 # refresh timer every 1 second
set :tmux, true # turn on tmux integration
set :tmux_theme, '#[fg=mycolor,bg=mycolor]#[fg=%s]%s#[fg=mycolor,bg=mycolor]'
# adds `-c --custom num` option, which allows on the fly timer
option :c, 'custom num', 'run with custom seconds' do |num|
set :timer, num.to_i
@run = true
end
# execute hook before each pomodoro
before do
`terminal-notifier -title "🍅 Pomodoro" -message "Let's get started!"`
end
# execute hook after each pomodoro
after do |seconds_left|
`terminal-notifier -title "🍅 Pomodoro" -message "Thyme's Up!" -sound "default"` if seconds_left == 0
end