add more descriptive error message

This commit is contained in:
Ruidy 2025-05-19 12:26:45 +02:00
parent 7345b1dc26
commit a52c7231b6
No known key found for this signature in database
GPG key ID: E00F51288CB857CC

9
tui.go
View file

@ -48,9 +48,14 @@ func (m model) Update(msg tea.Msg) (tea.Model, tea.Cmd) {
return m, nil
case TickMsg:
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 {
log.Fatal(err)
log.Printf("error sending notification: %v", err)
}
return m, tea.Quit
}