Thread: [See Bugtracker] Mac Notification Center Integration
View Single Post
  #15  
Old 20.03.2017, 14:21
mgpai mgpai is offline
Script Master
 
Join Date: Sep 2013
Posts: 1,528
Default

Quote:
Originally Posted by Jiaz View Post
does the terminal notifier work?
try in shell
@neoyoli,
If the 'terminal-notifier' is working correctly, you should be able to get notifications using this script.

Code:
// Notify download finished.
// Trigger: "A Download Stopped".
// OS: macOS 10.8 and higher.

if (link.isFinished()) {
    var notifier = "./terminal-notifier.app/Contents/MacOS/terminal-notifier"; // <- Set path to "terminal-notifier"
    var title = "JDownloader";
    var subtitle = "Download Finished";
    var message = link.getName();
    var sound = "default";

    callAsync(function() {}, notifier, "-title", title, "-subtitle", subtitle, "-message", message, "-sound", sound);
}

Last edited by Jiaz; 21.03.2017 at 10:55.
Reply With Quote