notify 0.1.1 → 0.2.0

Sign up to get free protection for your applications and to get access to all the features.
data/README.md CHANGED
@@ -22,6 +22,12 @@ Usage
22
22
  require 'notify'
23
23
  Notify.notify "title", "message"
24
24
 
25
+ or
26
+
27
+ ENV['NOTIFY'] = 'growlnotify'
28
+ require 'notify'
29
+ Notify.notify "title", "message"
30
+
25
31
  Copyright
26
32
  ---------
27
33
 
data/VERSION CHANGED
@@ -1 +1 @@
1
- 0.1.1
1
+ 0.2.0
@@ -0,0 +1,7 @@
1
+ if system('which growlnotify 2>&1 > /dev/null')
2
+ module Notify
3
+ def self.notify(title, message)
4
+ system 'growlnotify', '-t', title, '-m', message
5
+ end
6
+ end
7
+ end
@@ -1,4 +1,4 @@
1
- if RUBY_PLATFORM.downcase =~ /linux/ && system('which notify-send 2>&1 > /dev/null')
1
+ if system('which notify-send 2>&1 > /dev/null')
2
2
  module Notify
3
3
  def self.notify(title, message)
4
4
  system 'notify-send', title, message
File without changes
data/lib/notify.rb CHANGED
@@ -10,6 +10,7 @@ if ENV['NOTIFY']
10
10
  else
11
11
  unless defined? Notify
12
12
  Dir[File.join(__DIR__, "notify/*.rb")].each do |filename|
13
+ break if defined? Notify
13
14
  require filename
14
15
  end
15
16
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: notify
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.1
4
+ version: 0.2.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - jugyo
@@ -28,8 +28,9 @@ files:
28
28
  - Rakefile
29
29
  - VERSION
30
30
  - lib/notify.rb
31
- - lib/notify/growl.rb
31
+ - lib/notify/growlnotify.rb
32
32
  - lib/notify/notify-send.rb
33
+ - lib/notify/ruby-growl.rb
33
34
  - sample.rb
34
35
  has_rdoc: true
35
36
  homepage: http://github.com/jugyo/notify