mirror of
https://github.com/make-42/hayai.git
synced 2025-01-18 18:47:10 +01:00
.. | ||
alert_darwin.go | ||
alert_js.go | ||
alert_unix.go | ||
alert_unsupported.go | ||
alert_windows.go | ||
beeep.go | ||
beep_darwin.go | ||
beep_js.go | ||
beep_unix.go | ||
beep_unsupported.go | ||
beep_windows.go | ||
LICENSE | ||
notify_darwin.go | ||
notify_js.go | ||
notify_unix_nodbus.go | ||
notify_unix.go | ||
notify_unsupported.go | ||
notify_windows.go | ||
README.md |
beeep
beeep
provides a cross-platform library for sending desktop notifications, alerts and beeps.
Installation
go get -u github.com/gen2brain/beeep
Build tags
nodbus
- disablegodbus/dbus
and use onlynotify-send
Examples
err := beeep.Beep(beeep.DefaultFreq, beeep.DefaultDuration)
if err != nil {
panic(err)
}
err := beeep.Notify("Title", "Message body", "assets/information.png")
if err != nil {
panic(err)
}
err := beeep.Alert("Title", "Message body", "assets/warning.png")
if err != nil {
panic(err)
}