Categorygithub.com/electricbubble/mac-notification
repositorypackage
0.0.2
Repository: https://github.com/electricbubble/mac-notification.git
Documentation: pkg.go.dev

# README

macOS Notification

go doc go report license

Display a notification (macOS)

Installation

go get github.com/electricbubble/mac-notification

Usage

The sound can be one of the files in /System/Library/Sounds or in ~/Library/Sounds.

package main

import (
	macNotification "github.com/electricbubble/mac-notification"
)

func main() {
	notifier := macNotification.NewNotifier(macNotification.WithText("Hi, there!"), macNotification.WithSound("Submarine"))
	notifier.Push()
	notifier.Push(macNotification.WithText("Hi again"))
	// notifier.Text = "hey"
	// notifier.Push()
}

Thanks

Thank you JetBrains for providing free open source licenses