mirror of
https://github.com/rjNemo/pomodoro
synced 2026-06-12 10:16:39 +00:00
add more descriptive error message
This commit is contained in:
parent
7345b1dc26
commit
a52c7231b6
1 changed files with 7 additions and 2 deletions
9
tui.go
9
tui.go
|
|
@ -48,9 +48,14 @@ func (m model) Update(msg tea.Msg) (tea.Model, tea.Cmd) {
|
||||||
return m, nil
|
return m, nil
|
||||||
case TickMsg:
|
case TickMsg:
|
||||||
if m.progress.Percent() == 1.0 {
|
if m.progress.Percent() == 1.0 {
|
||||||
cmd := exec.Command("terminal-notifier", "-title", "Timer Complete", "-message", m.name, "-sound", "Crystal")
|
|
||||||
|
cmd := exec.Command("terminal-notifier",
|
||||||
|
"-title", "Timer Complete",
|
||||||
|
"-message", m.name,
|
||||||
|
"-ignoreDnD",
|
||||||
|
)
|
||||||
if err := cmd.Run(); err != nil {
|
if err := cmd.Run(); err != nil {
|
||||||
log.Fatal(err)
|
log.Printf("error sending notification: %v", err)
|
||||||
}
|
}
|
||||||
return m, tea.Quit
|
return m, tea.Quit
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue