add notifications

This commit is contained in:
2025-02-24 12:55:12 +01:00
parent 7ec12189e8
commit ebc0616ba1
5 changed files with 98 additions and 85 deletions

8
app.go
View File

@ -3,6 +3,8 @@ package main
import (
"context"
"fmt"
"github.com/gen2brain/beeep"
)
// App struct
@ -12,6 +14,7 @@ type App struct {
// NewApp creates a new App application struct
func NewApp() *App {
return &App{}
}
@ -19,6 +22,11 @@ func NewApp() *App {
// so we can call the runtime methods
func (a *App) startup(ctx context.Context) {
a.ctx = ctx
err := beeep.Notify("Hello", "World", "")
if err != nil {
fmt.Println(err)
}
}
// Greet returns a greeting for the given name