Created
June 22, 2013 14:17
-
-
Save bebraw/5841036 to your computer and use it in GitHub Desktop.
Pipe to OS X notifier. Requires https://npmjs.org/package/node-notifier and https://github.com/alloy/terminal-notifier . You can install latter through MacPorts (port install terminal-notifier). Usage: foo | ./notify.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env node | |
var notifier = require('node-notifier'); | |
var stdin = process.openStdin(); | |
stdin.setEncoding('utf8'); | |
stdin.on('data', function(chunk) { | |
notifier.notify({message: chunk}); | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment