apirunner 0.3.1 → 0.3.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/VERSION +1 -1
- data/apirunner.gemspec +1 -1
- data/lib/result.rb +8 -9
- metadata +3 -3
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.3.
|
1
|
+
0.3.2
|
data/apirunner.gemspec
CHANGED
data/lib/result.rb
CHANGED
@@ -71,20 +71,19 @@ class Result
|
|
71
71
|
|
72
72
|
def color_print(message, color)
|
73
73
|
case ENV['FORMAT']
|
74
|
-
|
75
|
-
|
76
|
-
|
77
|
-
|
78
|
-
|
79
|
-
end
|
74
|
+
when 'html' then "<span style='color:#{color}'>#{message}</span>"
|
75
|
+
when 'plain' then message
|
76
|
+
else
|
77
|
+
prefix, suffix = ansi_colors(color)
|
78
|
+
"#{prefix}#{message}#{suffix}"
|
80
79
|
end
|
81
80
|
end
|
82
81
|
|
83
82
|
def ansi_colors(color)
|
84
83
|
case color
|
85
|
-
|
86
|
-
|
87
|
-
|
84
|
+
when 'green' then ['\033[32m', '\033[0m']
|
85
|
+
when 'red' then ['\033[31m', '\033[0m']
|
86
|
+
else ['','']
|
88
87
|
end
|
89
88
|
end
|
90
89
|
|
metadata
CHANGED
@@ -5,8 +5,8 @@ version: !ruby/object:Gem::Version
|
|
5
5
|
segments:
|
6
6
|
- 0
|
7
7
|
- 3
|
8
|
-
-
|
9
|
-
version: 0.3.
|
8
|
+
- 2
|
9
|
+
version: 0.3.2
|
10
10
|
platform: ruby
|
11
11
|
authors:
|
12
12
|
- jan@moviepilot.com
|
@@ -262,7 +262,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
262
262
|
requirements:
|
263
263
|
- - ">="
|
264
264
|
- !ruby/object:Gem::Version
|
265
|
-
hash:
|
265
|
+
hash: -2758591287815107212
|
266
266
|
segments:
|
267
267
|
- 0
|
268
268
|
version: "0"
|