rspectacular 0.10.0 → 0.10.1
Sign up to get free protection for your applications and to get access to all the features.
- data/bin/rspectacular_test_bootstrap +18 -11
- data/lib/rspectacular/version.rb +1 -1
- metadata +1 -1
@@ -1,15 +1,22 @@
|
|
1
|
-
#!/usr/bin/env
|
1
|
+
#!/usr/bin/env ruby
|
2
2
|
|
3
|
-
|
3
|
+
fifo_dir = 'tmp'
|
4
|
+
fifo_file = 'test_fifo'
|
5
|
+
fifo_path = ['.', fifo_dir, fifo_file].join('/')
|
4
6
|
|
5
|
-
|
6
|
-
|
7
|
-
|
7
|
+
trap 2 do
|
8
|
+
File.delete(fifo_path)
|
9
|
+
exit
|
10
|
+
end
|
8
11
|
|
9
|
-
|
10
|
-
mkfifo ./tmp/test_fifo
|
11
|
-
fi
|
12
|
+
Dir.mkdir(fifo_dir) unless Dir.exists?(fifo_dir)
|
12
13
|
|
13
|
-
|
14
|
-
|
15
|
-
|
14
|
+
unless File.exists?(fifo_path)
|
15
|
+
%x{mkfifo #{fifo_path}}
|
16
|
+
end
|
17
|
+
|
18
|
+
input = open(fifo_path, 'r+')
|
19
|
+
|
20
|
+
while true do
|
21
|
+
system input.gets
|
22
|
+
end
|
data/lib/rspectacular/version.rb
CHANGED