scrolls 0.0.3 → 0.0.4
Sign up to get free protection for your applications and to get access to all the features.
- data/lib/scrolls/version.rb +1 -1
- data/lib/scrolls.rb +6 -3
- metadata +1 -1
data/lib/scrolls/version.rb
CHANGED
data/lib/scrolls.rb
CHANGED
@@ -16,8 +16,11 @@ module Scrolls
|
|
16
16
|
module Log
|
17
17
|
extend self
|
18
18
|
|
19
|
-
|
20
|
-
|
19
|
+
attr_accessor :stream
|
20
|
+
|
21
|
+
def start(stream = STDOUT)
|
22
|
+
@stream = stream
|
23
|
+
@stream.sync = true
|
21
24
|
log(:log => true, :start => true)
|
22
25
|
end
|
23
26
|
|
@@ -28,7 +31,7 @@ module Scrolls
|
|
28
31
|
def write(data)
|
29
32
|
msg = unparse(data)
|
30
33
|
mtx.synchronize do
|
31
|
-
|
34
|
+
stream.puts(msg)
|
32
35
|
end
|
33
36
|
end
|
34
37
|
|