class Guard::Notifier::Stumpwm
Constants
- VERSION
Public Class Methods
available?(opts={})
click to toggle source
# File lib/guard/notifier/stumpwm.rb, line 8 def self.available?(opts={}) !!`stumpish version` end
Public Instance Methods
notify(message, opts={})
click to toggle source
Calls superclass method
# File lib/guard/notifier/stumpwm.rb, line 12 def notify(message, opts={}) super color = case opts[:type] when :success 2 # green when :failed 1 # red else 3 end # yellow form = <<EOT (let ((*executing-stumpwm-command* nil)) (message "^#{color}#{opts[:title]}~%~%#{message}")) EOT `stumpish eval '#{form}'` end