From 53f3a62d388c1f3646f23925a8637099b2c9280d Mon Sep 17 00:00:00 2001 From: Sami Samhuri Date: Fri, 3 Mar 2017 22:25:05 -0800 Subject: [PATCH] update linky-notifier --- linky-notify | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/linky-notify b/linky-notify index 0a1c349..5ac457d 100755 --- a/linky-notify +++ b/linky-notify @@ -9,7 +9,7 @@ DEBUG = false def log_file @log_file ||= begin at_exit { log_file.close } - File.open('/Users/sjs/linky-notify.log', 'a') + File.open(File.expand_path('~/linky-notify.log'), 'a') end end @@ -39,7 +39,8 @@ def e(s) end def notify_command(title, url) - "/Users/sjs/.rbenv/shims/terminal-notifier -title #{e(title)} -message #{e(url)} -open #{e(url)} -sender com.apple.Terminal 2>&1" + notifier = File.expand_path '~/.rbenv/shims/terminal-notifier' + "#{notifier} -title #{e(title)} -message #{e(url)} -open #{e(url)} -actions 'Open' -closeLabel Ignore 2>&1" end def main