capistrano-notification 0.0.1 → 0.0.2

Sign up to get free protection for your applications and to get access to all the features.
Files changed (3) hide show
  1. data/VERSION +1 -1
  2. data/lib/capistrano-notification.rb +5 -3
  3. metadata +2 -2
data/VERSION CHANGED
@@ -1 +1 @@
1
- 0.0.1
1
+ 0.0.2
@@ -32,10 +32,12 @@ module CapistranoNotification
32
32
  end
33
33
  end
34
34
 
35
- def initialize(vars = {})
35
+ def initialize(vars = {}, &block)
36
36
  vars.each do |k, v|
37
37
  send k, v
38
38
  end
39
+
40
+ block.call(self) if block
39
41
  end
40
42
 
41
43
  validates_presence_of :name
@@ -61,8 +63,8 @@ module CapistranoNotification
61
63
  end
62
64
  end
63
65
 
64
- def irc(opts)
65
- add IRC.new(opts)
66
+ def irc(opts = {}, &block)
67
+ add IRC.new(opts, &block)
66
68
  end
67
69
 
68
70
  def add(notification)
metadata CHANGED
@@ -5,8 +5,8 @@ version: !ruby/object:Gem::Version
5
5
  segments:
6
6
  - 0
7
7
  - 0
8
- - 1
9
- version: 0.0.1
8
+ - 2
9
+ version: 0.0.2
10
10
  platform: ruby
11
11
  authors:
12
12
  - Keita Urashima