Terminal Notifier

From air
Revision as of 11:58, 20 October 2013 by Donsez (talk | contribs) (Created page with "terminal-notifier is a command-line tool to send Mac OS X User Notifications, which are available in Mac OS X 10.8 and higher. * https://github.com/alloy/terminal-notifier ...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

terminal-notifier is a command-line tool to send Mac OS X User Notifications, which are available in Mac OS X 10.8 and higher.


CLI

sudo gem install terminal-notifier
echo 'Piped Message Data!' | terminal-notifier -sound default
terminal-notifier -title 'Money' -message 'Check your Apple stock' -open 'http://finance.yahoo.com/q?s=AAPL'


With Node.js

Node.js wrapper : https://github.com/mikaelbr/node-notifier

npm install node-notifier
node terminal-notifier-example.js
var notifier = require('node-notifier');

notifier.notify({
    title: 'My application',
    message: 'New notification'
}, function(error, response) {
    console.log(response);
});