blue_shell 0.7 → 0.7.1

Sign up to get free protection for your applications and to get access to all the features.
@@ -21,9 +21,6 @@ module BlueShell
21
21
  # @param [Symbol] the stream to hook into (:stderr or :stdout)
22
22
  # @param [Lambda] the code to execute
23
23
  def add_hook(type, lambda)
24
- # TODO: This should be a custom error
25
- raise "May not add hooks while executing." if @executing
26
-
27
24
  @hooks[type] << lambda
28
25
  end
29
26
 
@@ -68,7 +65,7 @@ module BlueShell
68
65
  end
69
66
 
70
67
  def read_thread(type, stream, sink)
71
- Thread.new(@hooks[type], stream, sink) do |hooks, stream, sink|
68
+ Thread.new(@hooks[type].dup, stream, sink) do |hooks, stream, sink|
72
69
  line = nil
73
70
  br = BufferedReader.new(InputStreamReader.new(stream))
74
71
 
@@ -1,3 +1,3 @@
1
1
  module BlueShell
2
- VERSION = "0.7"
2
+ VERSION = "0.7.1"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: blue_shell
3
3
  version: !ruby/object:Gem::Version
4
- version: '0.7'
4
+ version: 0.7.1
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors: