Skip to content

Instantly share code, notes, and snippets.

@captbrogers
Created November 11, 2013 15:59
Show Gist options
  • Save captbrogers/7415494 to your computer and use it in GitHub Desktop.
Save captbrogers/7415494 to your computer and use it in GitHub Desktop.
Tiny bash to pipe the output of grunt to the system notification
#!/bin/bash
# take the output of grunt and strip the unicode color characters
OUTPUT=`grunt | sed -r "s/\x1B\[([0-9]{1,2}(;[0-9]{1,2})?)?[m|K]//g"`
/usr/bin/notify-send -t 1000 Grunt\ Output "${OUTPUT}"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment