From 7994c289aae7662fee9b86f9424d230c7b612b3d Mon Sep 17 00:00:00 2001 From: Tulir Asokan Date: Wed, 21 Mar 2018 00:21:16 +0200 Subject: Refactor some things and format everything --- notification/notify_darwin.go | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) (limited to 'notification/notify_darwin.go') diff --git a/notification/notify_darwin.go b/notification/notify_darwin.go index 3a4a8c2..f7a2d89 100644 --- a/notification/notify_darwin.go +++ b/notification/notify_darwin.go @@ -17,8 +17,8 @@ package notification import ( - "os/exec" "fmt" + "os/exec" "strings" ) @@ -37,9 +37,9 @@ func Send(title, text string, critical bool) error { if critical { args = append(args, "-timeout", "30") } -// if len(iconPath) > 0 { -// args = append(args, "-appIcon", iconPath) -// } +// if len(iconPath) > 0 { +// args = append(args, "-appIcon", iconPath) +// } return exec.Command("terminal-notifier", args...).Run() } title = strings.Replace(title, `"`, `\"`, -1) @@ -47,4 +47,3 @@ func Send(title, text string, critical bool) error { notification := fmt.Sprintf("display notification \"%s\" with title \"gomuks\" subtitle \"%s\"", text, title) return exec.Command("osascript", "-e", notification).Run() } - -- cgit v1.2.3