Skip to content

Instantly share code, notes, and snippets.

@hachesilva
Created January 6, 2021 22:09
Show Gist options
  • Save hachesilva/0a3fe12671078d822188ccf153a16d8b to your computer and use it in GitHub Desktop.
Save hachesilva/0a3fe12671078d822188ccf153a16d8b to your computer and use it in GitHub Desktop.
Notifyme me when a terminal command is done
# Source: https://news.ycombinator.com/item?id=25381535
# Usage: $ LONG-COMMAND; notifyme
function notifyme() {
MSG=${1:-'Terminal is done'}
TITLE=${2:-"Done!"}
osascript -e "display notification \"${MSG}\" with title \"${TITLE}\""
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment