Skip to content

Instantly share code, notes, and snippets.

Forked from zoul/build-notifier.rb
Last active July 3, 2018 13:49
What would you like to do?
Posts a message to the OS X notification center when a Jekyll build is finished. Requires TerminalNotifier, see or “gem install terminal-notifier”.
require 'terminal-notifier'
module Jekyll
class Site
alias jekyll_process process
def process
TerminalNotifier.notify("🍻 Jekyll rebuild finished")
rescue => e
TerminalNotifier.notify("💥 Jekyll rebuild failed: #{e.message}")
raise e
rescue LoadError
# nothing
Copy link

kerim commented Dec 3, 2016

Please forgive a newbie question, but what do I do with the file build-notifier.rb? I understand that I need to install the gem terminal-notifier, but I'm not sure how to use the code you have here with that?

Copy link

Supposedly you install it in the _plugins/ directory, but I cannot get it to work.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment