fluent_command_builder 0.1.17 → 0.1.18
Sign up to get free protection for your applications and to get access to all the features.
- data/lib/fluent_command_builder.rb +1 -0
- data/lib/fluent_command_builder/command_base.rb +10 -0
- data/lib/fluent_command_builder/command_builder.rb +11 -0
- data/lib/fluent_command_builder/command_builders/aspnet_compiler_20.rb +2 -9
- data/lib/fluent_command_builder/command_builders/aspnet_compiler_35.rb +2 -9
- data/lib/fluent_command_builder/command_builders/aspnet_compiler_40.rb +2 -9
- data/lib/fluent_command_builder/command_builders/bundle_11.rb +309 -0
- data/lib/fluent_command_builder/command_builders/cucumber_11.rb +2 -9
- data/lib/fluent_command_builder/command_builders/dotcover_11.rb +9 -72
- data/lib/fluent_command_builder/command_builders/installutil_11.rb +2 -9
- data/lib/fluent_command_builder/command_builders/installutil_20.rb +2 -9
- data/lib/fluent_command_builder/command_builders/installutil_35.rb +2 -9
- data/lib/fluent_command_builder/command_builders/installutil_40.rb +2 -9
- data/lib/fluent_command_builder/command_builders/msbuild_20.rb +2 -9
- data/lib/fluent_command_builder/command_builders/msbuild_30.rb +2 -9
- data/lib/fluent_command_builder/command_builders/msbuild_35.rb +2 -9
- data/lib/fluent_command_builder/command_builders/msbuild_40.rb +2 -9
- data/lib/fluent_command_builder/command_builders/msdeploy_40.rb +2 -9
- data/lib/fluent_command_builder/command_builders/mstest_2005.rb +2 -9
- data/lib/fluent_command_builder/command_builders/mstest_2008.rb +2 -9
- data/lib/fluent_command_builder/command_builders/mstest_2010.rb +2 -9
- data/lib/fluent_command_builder/command_builders/netsh_2008.rb +11 -90
- data/lib/fluent_command_builder/command_builders/nunit_25.rb +3 -10
- data/lib/fluent_command_builder/command_builders/rake_09.rb +3 -10
- data/lib/fluent_command_builder/command_builders/sevenzip_92.rb +10 -81
- data/lib/fluent_command_builder/command_builders/simian_23.rb +2 -9
- data/lib/fluent_command_builder/command_builders/tf_2010.rb +80 -535
- data/lib/fluent_command_builder/command_builders/tf_tee_2010.rb +76 -531
- metadata +4 -2
@@ -1,6 +1,7 @@
|
|
1
1
|
require File.expand_path(File.dirname(__FILE__) + '/fluent_command_builder/command_builders/aspnet_compiler_20.rb')
|
2
2
|
require File.expand_path(File.dirname(__FILE__) + '/fluent_command_builder/command_builders/aspnet_compiler_35.rb')
|
3
3
|
require File.expand_path(File.dirname(__FILE__) + '/fluent_command_builder/command_builders/aspnet_compiler_40.rb')
|
4
|
+
require File.expand_path(File.dirname(__FILE__) + '/fluent_command_builder/command_builders/bundle_11.rb')
|
4
5
|
require File.expand_path(File.dirname(__FILE__) + '/fluent_command_builder/command_builders/cucumber_11.rb')
|
5
6
|
require File.expand_path(File.dirname(__FILE__) + '/fluent_command_builder/command_builders/dotcover_11.rb')
|
6
7
|
require File.expand_path(File.dirname(__FILE__) + '/fluent_command_builder/command_builders/installutil_11.rb')
|
@@ -1,3 +1,5 @@
|
|
1
|
+
require File.expand_path(File.dirname(__FILE__) + '/command_base')
|
2
|
+
|
1
3
|
module FluentCommandBuilder
|
2
4
|
class CommandBuilder
|
3
5
|
|
@@ -6,6 +8,15 @@ module FluentCommandBuilder
|
|
6
8
|
end
|
7
9
|
|
8
10
|
def format value, delimiter=nil, key_value_separator=nil
|
11
|
+
|
12
|
+
if value.kind_of? Array and delimiter.nil?
|
13
|
+
return array_to_s(value.map { |v| quote_if_includes_space v }, ' ')
|
14
|
+
end
|
15
|
+
|
16
|
+
if value.kind_of? CommandBase
|
17
|
+
return value.to_s
|
18
|
+
end
|
19
|
+
|
9
20
|
value_as_array = case
|
10
21
|
when value.kind_of?(Hash)
|
11
22
|
hash_to_array value, key_value_separator
|
@@ -1,9 +1,10 @@
|
|
1
|
+
require File.expand_path(File.dirname(__FILE__) + '/../command_base')
|
1
2
|
require File.expand_path(File.dirname(__FILE__) + '/../command_builder')
|
2
3
|
|
3
4
|
module FluentCommandBuilder
|
4
5
|
module AspnetCompiler
|
5
6
|
module V20
|
6
|
-
class AspnetCompiler
|
7
|
+
class AspnetCompiler < CommandBase
|
7
8
|
def initialize builder, target_dir=nil
|
8
9
|
@builder = builder
|
9
10
|
@builder.append 'aspnet_compiler'
|
@@ -68,14 +69,6 @@ module FluentCommandBuilder
|
|
68
69
|
def to_s
|
69
70
|
@builder.to_s
|
70
71
|
end
|
71
|
-
def execute
|
72
|
-
begin
|
73
|
-
require 'rake'
|
74
|
-
sh to_s
|
75
|
-
rescue LoadError
|
76
|
-
system to_s
|
77
|
-
end
|
78
|
-
end
|
79
72
|
end
|
80
73
|
def aspnet_compiler target_dir=nil
|
81
74
|
AspnetCompiler.new CommandBuilder.new, target_dir
|
@@ -1,9 +1,10 @@
|
|
1
|
+
require File.expand_path(File.dirname(__FILE__) + '/../command_base')
|
1
2
|
require File.expand_path(File.dirname(__FILE__) + '/../command_builder')
|
2
3
|
|
3
4
|
module FluentCommandBuilder
|
4
5
|
module AspnetCompiler
|
5
6
|
module V35
|
6
|
-
class AspnetCompiler
|
7
|
+
class AspnetCompiler < CommandBase
|
7
8
|
def initialize builder, target_dir=nil
|
8
9
|
@builder = builder
|
9
10
|
@builder.append 'aspnet_compiler'
|
@@ -68,14 +69,6 @@ module FluentCommandBuilder
|
|
68
69
|
def to_s
|
69
70
|
@builder.to_s
|
70
71
|
end
|
71
|
-
def execute
|
72
|
-
begin
|
73
|
-
require 'rake'
|
74
|
-
sh to_s
|
75
|
-
rescue LoadError
|
76
|
-
system to_s
|
77
|
-
end
|
78
|
-
end
|
79
72
|
end
|
80
73
|
def aspnet_compiler target_dir=nil
|
81
74
|
AspnetCompiler.new CommandBuilder.new, target_dir
|
@@ -1,9 +1,10 @@
|
|
1
|
+
require File.expand_path(File.dirname(__FILE__) + '/../command_base')
|
1
2
|
require File.expand_path(File.dirname(__FILE__) + '/../command_builder')
|
2
3
|
|
3
4
|
module FluentCommandBuilder
|
4
5
|
module AspnetCompiler
|
5
6
|
module V40
|
6
|
-
class AspnetCompiler
|
7
|
+
class AspnetCompiler < CommandBase
|
7
8
|
def initialize builder, target_dir=nil
|
8
9
|
@builder = builder
|
9
10
|
@builder.append 'aspnet_compiler'
|
@@ -68,14 +69,6 @@ module FluentCommandBuilder
|
|
68
69
|
def to_s
|
69
70
|
@builder.to_s
|
70
71
|
end
|
71
|
-
def execute
|
72
|
-
begin
|
73
|
-
require 'rake'
|
74
|
-
sh to_s
|
75
|
-
rescue LoadError
|
76
|
-
system to_s
|
77
|
-
end
|
78
|
-
end
|
79
72
|
end
|
80
73
|
def aspnet_compiler target_dir=nil
|
81
74
|
AspnetCompiler.new CommandBuilder.new, target_dir
|
@@ -0,0 +1,309 @@
|
|
1
|
+
require File.expand_path(File.dirname(__FILE__) + '/../command_base')
|
2
|
+
require File.expand_path(File.dirname(__FILE__) + '/../command_builder')
|
3
|
+
|
4
|
+
module FluentCommandBuilder
|
5
|
+
module Bundle
|
6
|
+
module V11
|
7
|
+
class Bundle < CommandBase
|
8
|
+
def initialize builder
|
9
|
+
@builder = builder
|
10
|
+
@builder.append 'bundle'
|
11
|
+
end
|
12
|
+
def cache
|
13
|
+
Cache.new @builder
|
14
|
+
end
|
15
|
+
def check
|
16
|
+
Check.new @builder
|
17
|
+
end
|
18
|
+
def clean
|
19
|
+
Clean.new @builder
|
20
|
+
end
|
21
|
+
def config name, value=nil
|
22
|
+
@builder.append " config #{@builder.format name}"
|
23
|
+
@builder.append " #{@builder.format value}" unless value.nil?
|
24
|
+
self
|
25
|
+
end
|
26
|
+
def console group=nil
|
27
|
+
@builder.append ' console'
|
28
|
+
@builder.append " #{@builder.format group}" unless group.nil?
|
29
|
+
self
|
30
|
+
end
|
31
|
+
def exec command
|
32
|
+
@builder.append " exec #{@builder.format command}"
|
33
|
+
self
|
34
|
+
end
|
35
|
+
def gem gem
|
36
|
+
Gem.new @builder, gem
|
37
|
+
end
|
38
|
+
def init
|
39
|
+
Init.new @builder
|
40
|
+
end
|
41
|
+
def install
|
42
|
+
Install.new @builder
|
43
|
+
end
|
44
|
+
def open gem
|
45
|
+
@builder.append " open #{@builder.format gem}"
|
46
|
+
self
|
47
|
+
end
|
48
|
+
def outdated gem=nil
|
49
|
+
Outdated.new @builder, gem
|
50
|
+
end
|
51
|
+
def package
|
52
|
+
Package.new @builder
|
53
|
+
end
|
54
|
+
def show gem=nil
|
55
|
+
Show.new @builder, gem
|
56
|
+
end
|
57
|
+
def update gem=nil
|
58
|
+
Update.new @builder, gem
|
59
|
+
end
|
60
|
+
def version
|
61
|
+
@builder.append ' version'
|
62
|
+
self
|
63
|
+
end
|
64
|
+
def viz
|
65
|
+
Viz.new @builder
|
66
|
+
end
|
67
|
+
def to_s
|
68
|
+
@builder.to_s
|
69
|
+
end
|
70
|
+
end
|
71
|
+
class Cache < CommandBase
|
72
|
+
def initialize builder
|
73
|
+
@builder = builder
|
74
|
+
@builder.append ' cache'
|
75
|
+
end
|
76
|
+
def no_prune
|
77
|
+
@builder.append ' --no-prune'
|
78
|
+
self
|
79
|
+
end
|
80
|
+
def to_s
|
81
|
+
@builder.to_s
|
82
|
+
end
|
83
|
+
end
|
84
|
+
class Check < CommandBase
|
85
|
+
def initialize builder
|
86
|
+
@builder = builder
|
87
|
+
@builder.append ' check'
|
88
|
+
end
|
89
|
+
def gemfile file
|
90
|
+
@builder.append " --gemfile=#{@builder.format file}"
|
91
|
+
self
|
92
|
+
end
|
93
|
+
def path path
|
94
|
+
@builder.append " --path=#{@builder.format path}"
|
95
|
+
self
|
96
|
+
end
|
97
|
+
def to_s
|
98
|
+
@builder.to_s
|
99
|
+
end
|
100
|
+
end
|
101
|
+
class Clean < CommandBase
|
102
|
+
def initialize builder
|
103
|
+
@builder = builder
|
104
|
+
@builder.append ' clean'
|
105
|
+
end
|
106
|
+
def force
|
107
|
+
@builder.append ' --force'
|
108
|
+
self
|
109
|
+
end
|
110
|
+
def to_s
|
111
|
+
@builder.to_s
|
112
|
+
end
|
113
|
+
end
|
114
|
+
class Gem < CommandBase
|
115
|
+
def initialize builder, gem
|
116
|
+
@builder = builder
|
117
|
+
@builder.append " gem #{@builder.format gem}"
|
118
|
+
end
|
119
|
+
def bin
|
120
|
+
@builder.append ' --bin'
|
121
|
+
self
|
122
|
+
end
|
123
|
+
def to_s
|
124
|
+
@builder.to_s
|
125
|
+
end
|
126
|
+
end
|
127
|
+
class Init < CommandBase
|
128
|
+
def initialize builder
|
129
|
+
@builder = builder
|
130
|
+
@builder.append ' init'
|
131
|
+
end
|
132
|
+
def gemspec file
|
133
|
+
@builder.append " --gemspec=#{@builder.format file}"
|
134
|
+
self
|
135
|
+
end
|
136
|
+
def to_s
|
137
|
+
@builder.to_s
|
138
|
+
end
|
139
|
+
end
|
140
|
+
class Install < CommandBase
|
141
|
+
def initialize builder
|
142
|
+
@builder = builder
|
143
|
+
@builder.append ' install'
|
144
|
+
end
|
145
|
+
def binstubs path
|
146
|
+
@builder.append " --binstubs=#{@builder.format path}"
|
147
|
+
self
|
148
|
+
end
|
149
|
+
def clean
|
150
|
+
@builder.append ' --clean'
|
151
|
+
self
|
152
|
+
end
|
153
|
+
def deployment
|
154
|
+
@builder.append ' --deployment'
|
155
|
+
self
|
156
|
+
end
|
157
|
+
def frozen
|
158
|
+
@builder.append ' --frozen'
|
159
|
+
self
|
160
|
+
end
|
161
|
+
def full_index
|
162
|
+
@builder.append ' --full-index'
|
163
|
+
self
|
164
|
+
end
|
165
|
+
def gemfile file
|
166
|
+
@builder.append " --gemfile=#{@builder.format file}"
|
167
|
+
self
|
168
|
+
end
|
169
|
+
def local
|
170
|
+
@builder.append ' --local'
|
171
|
+
self
|
172
|
+
end
|
173
|
+
def no_cache
|
174
|
+
@builder.append ' --no-cache'
|
175
|
+
self
|
176
|
+
end
|
177
|
+
def no_prune
|
178
|
+
@builder.append ' --no-prune'
|
179
|
+
self
|
180
|
+
end
|
181
|
+
def path path
|
182
|
+
@builder.append " --path=#{@builder.format path}"
|
183
|
+
self
|
184
|
+
end
|
185
|
+
def quiet
|
186
|
+
@builder.append ' --quiet'
|
187
|
+
self
|
188
|
+
end
|
189
|
+
def shebang string
|
190
|
+
@builder.append " --shebang=#{@builder.format string}"
|
191
|
+
self
|
192
|
+
end
|
193
|
+
def standalone array
|
194
|
+
@builder.append " --standalone=#{@builder.format array}"
|
195
|
+
self
|
196
|
+
end
|
197
|
+
def system
|
198
|
+
@builder.append ' --system'
|
199
|
+
self
|
200
|
+
end
|
201
|
+
def without group
|
202
|
+
@builder.append " --without=#{@builder.format group}"
|
203
|
+
self
|
204
|
+
end
|
205
|
+
def to_s
|
206
|
+
@builder.to_s
|
207
|
+
end
|
208
|
+
end
|
209
|
+
class Outdated < CommandBase
|
210
|
+
def initialize builder, gem=nil
|
211
|
+
@builder = builder
|
212
|
+
@builder.append ' outdated'
|
213
|
+
@builder.append " #{@builder.format gem}" unless gem.nil?
|
214
|
+
end
|
215
|
+
def local
|
216
|
+
@builder.append ' --local'
|
217
|
+
self
|
218
|
+
end
|
219
|
+
def pre
|
220
|
+
@builder.append ' --pre'
|
221
|
+
self
|
222
|
+
end
|
223
|
+
def source
|
224
|
+
@builder.append ' --source'
|
225
|
+
self
|
226
|
+
end
|
227
|
+
def to_s
|
228
|
+
@builder.to_s
|
229
|
+
end
|
230
|
+
end
|
231
|
+
class Package < CommandBase
|
232
|
+
def initialize builder
|
233
|
+
@builder = builder
|
234
|
+
@builder.append ' package'
|
235
|
+
end
|
236
|
+
def no_prune
|
237
|
+
@builder.append ' --no-prune'
|
238
|
+
self
|
239
|
+
end
|
240
|
+
def to_s
|
241
|
+
@builder.to_s
|
242
|
+
end
|
243
|
+
end
|
244
|
+
class Show < CommandBase
|
245
|
+
def initialize builder, gem=nil
|
246
|
+
@builder = builder
|
247
|
+
@builder.append ' show'
|
248
|
+
@builder.append " #{@builder.format gem}" unless gem.nil?
|
249
|
+
end
|
250
|
+
def paths
|
251
|
+
@builder.append ' --paths'
|
252
|
+
self
|
253
|
+
end
|
254
|
+
def to_s
|
255
|
+
@builder.to_s
|
256
|
+
end
|
257
|
+
end
|
258
|
+
class Update < CommandBase
|
259
|
+
def initialize builder, gem=nil
|
260
|
+
@builder = builder
|
261
|
+
@builder.append ' update'
|
262
|
+
@builder.append " #{@builder.format gem}" unless gem.nil?
|
263
|
+
end
|
264
|
+
def local
|
265
|
+
@builder.append ' --local'
|
266
|
+
self
|
267
|
+
end
|
268
|
+
def source source
|
269
|
+
@builder.append " --source=#{@builder.format source}"
|
270
|
+
self
|
271
|
+
end
|
272
|
+
def to_s
|
273
|
+
@builder.to_s
|
274
|
+
end
|
275
|
+
end
|
276
|
+
class Viz < CommandBase
|
277
|
+
def initialize builder
|
278
|
+
@builder = builder
|
279
|
+
@builder.append ' viz'
|
280
|
+
end
|
281
|
+
def file file
|
282
|
+
@builder.append " --file=#{@builder.format file}"
|
283
|
+
self
|
284
|
+
end
|
285
|
+
def format format
|
286
|
+
@builder.append " --format=#{@builder.format format}"
|
287
|
+
self
|
288
|
+
end
|
289
|
+
def requirements
|
290
|
+
@builder.append ' --requirements'
|
291
|
+
self
|
292
|
+
end
|
293
|
+
def version
|
294
|
+
@builder.append ' --version'
|
295
|
+
self
|
296
|
+
end
|
297
|
+
def to_s
|
298
|
+
@builder.to_s
|
299
|
+
end
|
300
|
+
end
|
301
|
+
def bundle
|
302
|
+
Bundle.new CommandBuilder.new
|
303
|
+
end
|
304
|
+
end
|
305
|
+
end
|
306
|
+
def bundle_11
|
307
|
+
Bundle::V11::Bundle.new CommandBuilder.new
|
308
|
+
end
|
309
|
+
end
|
@@ -1,9 +1,10 @@
|
|
1
|
+
require File.expand_path(File.dirname(__FILE__) + '/../command_base')
|
1
2
|
require File.expand_path(File.dirname(__FILE__) + '/../command_builder')
|
2
3
|
|
3
4
|
module FluentCommandBuilder
|
4
5
|
module Cucumber
|
5
6
|
module V11
|
6
|
-
class Cucumber
|
7
|
+
class Cucumber < CommandBase
|
7
8
|
def initialize builder, feature=nil
|
8
9
|
@builder = builder
|
9
10
|
@builder.append 'cucumber'
|
@@ -128,14 +129,6 @@ module FluentCommandBuilder
|
|
128
129
|
def to_s
|
129
130
|
@builder.to_s
|
130
131
|
end
|
131
|
-
def execute
|
132
|
-
begin
|
133
|
-
require 'rake'
|
134
|
-
sh to_s
|
135
|
-
rescue LoadError
|
136
|
-
system to_s
|
137
|
-
end
|
138
|
-
end
|
139
132
|
end
|
140
133
|
def cucumber feature=nil
|
141
134
|
Cucumber.new CommandBuilder.new, feature
|