af 0.3.12.2 → 0.3.12.3
Sign up to get free protection for your applications and to get access to all the features.
- data/lib/cli/runner.rb +45 -45
- data/lib/cli/version.rb +1 -1
- metadata +85 -125
data/lib/cli/runner.rb
CHANGED
@@ -136,11 +136,11 @@ class VMC::Cli::Runner
|
|
136
136
|
case verb
|
137
137
|
|
138
138
|
when 'version'
|
139
|
-
usage('
|
139
|
+
usage('af version')
|
140
140
|
set_cmd(:misc, :version)
|
141
141
|
|
142
142
|
when 'target'
|
143
|
-
usage('
|
143
|
+
usage('af target [url] [--url]')
|
144
144
|
if @args.size == 1
|
145
145
|
set_cmd(:misc, :set_target, 1)
|
146
146
|
else
|
@@ -148,31 +148,31 @@ class VMC::Cli::Runner
|
|
148
148
|
end
|
149
149
|
|
150
150
|
when 'targets'
|
151
|
-
usage('
|
151
|
+
usage('af targets')
|
152
152
|
set_cmd(:misc, :targets)
|
153
153
|
|
154
154
|
when 'tokens'
|
155
|
-
usage('
|
155
|
+
usage('af tokens')
|
156
156
|
set_cmd(:misc, :tokens)
|
157
157
|
|
158
158
|
when 'info'
|
159
|
-
usage('
|
159
|
+
usage('af info')
|
160
160
|
set_cmd(:misc, :info)
|
161
161
|
|
162
162
|
when 'runtimes'
|
163
|
-
usage('
|
163
|
+
usage('af runtimes')
|
164
164
|
set_cmd(:misc, :runtimes)
|
165
165
|
|
166
166
|
when 'frameworks'
|
167
|
-
usage('
|
167
|
+
usage('af frameworks')
|
168
168
|
set_cmd(:misc, :frameworks)
|
169
169
|
|
170
170
|
when 'user'
|
171
|
-
usage('
|
171
|
+
usage('af user')
|
172
172
|
set_cmd(:user, :info)
|
173
173
|
|
174
174
|
when 'login'
|
175
|
-
usage('
|
175
|
+
usage('af login [email] [--email EMAIL] [--passwd PASS]')
|
176
176
|
if @args.size == 1
|
177
177
|
set_cmd(:user, :login, 1)
|
178
178
|
else
|
@@ -180,11 +180,11 @@ class VMC::Cli::Runner
|
|
180
180
|
end
|
181
181
|
|
182
182
|
when 'logout'
|
183
|
-
usage('
|
183
|
+
usage('af logout')
|
184
184
|
set_cmd(:user, :logout)
|
185
185
|
|
186
186
|
when 'passwd'
|
187
|
-
usage('
|
187
|
+
usage('af passwd')
|
188
188
|
if @args.size == 1
|
189
189
|
set_cmd(:user, :change_password, 1)
|
190
190
|
else
|
@@ -192,7 +192,7 @@ class VMC::Cli::Runner
|
|
192
192
|
end
|
193
193
|
|
194
194
|
when 'add-user', 'add_user', 'create_user', 'create-user', 'register'
|
195
|
-
usage('
|
195
|
+
usage('af add-user [user] [--email EMAIL] [--passwd PASS]')
|
196
196
|
if @args.size == 1
|
197
197
|
set_cmd(:admin, :add_user, 1)
|
198
198
|
else
|
@@ -200,39 +200,39 @@ class VMC::Cli::Runner
|
|
200
200
|
end
|
201
201
|
|
202
202
|
when 'delete-user', 'delete_user', 'unregister'
|
203
|
-
usage('
|
203
|
+
usage('af delete-user <user>')
|
204
204
|
set_cmd(:admin, :delete_user, 1)
|
205
205
|
|
206
206
|
when 'users'
|
207
|
-
usage('
|
207
|
+
usage('af users')
|
208
208
|
set_cmd(:admin, :users)
|
209
209
|
|
210
210
|
when 'apps'
|
211
|
-
usage('
|
211
|
+
usage('af apps')
|
212
212
|
set_cmd(:apps, :apps)
|
213
213
|
|
214
214
|
when 'list'
|
215
|
-
usage('
|
215
|
+
usage('af list')
|
216
216
|
set_cmd(:apps, :list)
|
217
217
|
|
218
218
|
when 'start'
|
219
|
-
usage('
|
219
|
+
usage('af start <appname>')
|
220
220
|
set_cmd(:apps, :start, 1)
|
221
221
|
|
222
222
|
when 'stop'
|
223
|
-
usage('
|
223
|
+
usage('af stop <appname>')
|
224
224
|
set_cmd(:apps, :stop, 1)
|
225
225
|
|
226
226
|
when 'restart'
|
227
|
-
usage('
|
227
|
+
usage('af restart <appname>')
|
228
228
|
set_cmd(:apps, :restart, 1)
|
229
229
|
|
230
230
|
when 'rename'
|
231
|
-
usage('
|
231
|
+
usage('af rename <appname> <newname>')
|
232
232
|
set_cmd(:apps, :rename, 2)
|
233
233
|
|
234
234
|
when 'mem'
|
235
|
-
usage('
|
235
|
+
usage('af mem <appname> [memsize]')
|
236
236
|
if @args.size == 2
|
237
237
|
set_cmd(:apps, :mem, 2)
|
238
238
|
else
|
@@ -240,19 +240,19 @@ class VMC::Cli::Runner
|
|
240
240
|
end
|
241
241
|
|
242
242
|
when 'stats'
|
243
|
-
usage('
|
243
|
+
usage('af stats <appname>')
|
244
244
|
set_cmd(:apps, :stats, 1)
|
245
245
|
|
246
246
|
when 'map'
|
247
|
-
usage('
|
247
|
+
usage('af map <appname> <url>')
|
248
248
|
set_cmd(:apps, :map, 2)
|
249
249
|
|
250
250
|
when 'unmap'
|
251
|
-
usage('
|
251
|
+
usage('af unmap <appname> <url>')
|
252
252
|
set_cmd(:apps, :unmap, 2)
|
253
253
|
|
254
254
|
when 'delete'
|
255
|
-
usage('
|
255
|
+
usage('af delete <appname>')
|
256
256
|
if @options[:all] && @args.size == 0
|
257
257
|
set_cmd(:apps, :delete)
|
258
258
|
else
|
@@ -260,7 +260,7 @@ class VMC::Cli::Runner
|
|
260
260
|
end
|
261
261
|
|
262
262
|
when 'files'
|
263
|
-
usage('
|
263
|
+
usage('af files <appname> [path] [--instance N] [--all] [--prefix]')
|
264
264
|
if @args.size == 1
|
265
265
|
set_cmd(:apps, :files, 1)
|
266
266
|
else
|
@@ -268,28 +268,28 @@ class VMC::Cli::Runner
|
|
268
268
|
end
|
269
269
|
|
270
270
|
when 'logs'
|
271
|
-
usage('
|
271
|
+
usage('af logs <appname> [--instance N] [--all] [--prefix]')
|
272
272
|
set_cmd(:apps, :logs, 1)
|
273
273
|
|
274
274
|
when 'instances', 'scale'
|
275
275
|
if @args.size == 1
|
276
|
-
usage('
|
276
|
+
usage('af instances <appname>')
|
277
277
|
set_cmd(:apps, :instances, 1)
|
278
278
|
else
|
279
|
-
usage('
|
279
|
+
usage('af instances <appname> <num|delta>')
|
280
280
|
set_cmd(:apps, :instances, 2)
|
281
281
|
end
|
282
282
|
|
283
283
|
when 'crashes'
|
284
|
-
usage('
|
284
|
+
usage('af crashes <appname>')
|
285
285
|
set_cmd(:apps, :crashes, 1)
|
286
286
|
|
287
287
|
when 'crashlogs'
|
288
|
-
usage('
|
288
|
+
usage('af crashlogs <appname>')
|
289
289
|
set_cmd(:apps, :crashlogs, 1)
|
290
290
|
|
291
291
|
when 'push'
|
292
|
-
usage('
|
292
|
+
usage('af push [appname] [--path PATH] [--url URL] [--instances N] [--mem] [--runtime RUNTIME] [--no-start]')
|
293
293
|
if @args.size == 1
|
294
294
|
set_cmd(:apps, :push, 1)
|
295
295
|
else
|
@@ -297,19 +297,19 @@ class VMC::Cli::Runner
|
|
297
297
|
end
|
298
298
|
|
299
299
|
when 'update'
|
300
|
-
usage('
|
300
|
+
usage('af update <appname> [--path PATH]')
|
301
301
|
set_cmd(:apps, :update, 1)
|
302
302
|
|
303
303
|
when 'services'
|
304
|
-
usage('
|
304
|
+
usage('af services')
|
305
305
|
set_cmd(:services, :services)
|
306
306
|
|
307
307
|
when 'env'
|
308
|
-
usage('
|
308
|
+
usage('af env <appname>')
|
309
309
|
set_cmd(:apps, :environment, 1)
|
310
310
|
|
311
311
|
when 'env-add'
|
312
|
-
usage('
|
312
|
+
usage('af env-add <appname> <variable[=]value>')
|
313
313
|
if @args.size == 2
|
314
314
|
set_cmd(:apps, :environment_add, 2)
|
315
315
|
elsif @args.size == 3
|
@@ -317,18 +317,18 @@ class VMC::Cli::Runner
|
|
317
317
|
end
|
318
318
|
|
319
319
|
when 'env-del'
|
320
|
-
usage('
|
320
|
+
usage('af env-del <appname> <variable>')
|
321
321
|
set_cmd(:apps, :environment_del, 2)
|
322
322
|
|
323
323
|
when 'create-service', 'create_service'
|
324
|
-
usage('
|
324
|
+
usage('af create-service [service] [servicename] [appname] [--name servicename] [--bind appname]')
|
325
325
|
set_cmd(:services, :create_service) if @args.size == 0
|
326
326
|
set_cmd(:services, :create_service, 1) if @args.size == 1
|
327
327
|
set_cmd(:services, :create_service, 2) if @args.size == 2
|
328
328
|
set_cmd(:services, :create_service, 3) if @args.size == 3
|
329
329
|
|
330
330
|
when 'delete-service', 'delete_service'
|
331
|
-
usage('
|
331
|
+
usage('af delete-service <service>')
|
332
332
|
if @args.size == 1
|
333
333
|
set_cmd(:services, :delete_service, 1)
|
334
334
|
else
|
@@ -336,23 +336,23 @@ class VMC::Cli::Runner
|
|
336
336
|
end
|
337
337
|
|
338
338
|
when 'bind-service', 'bind_service'
|
339
|
-
usage('
|
339
|
+
usage('af bind-service <servicename> <appname>')
|
340
340
|
set_cmd(:services, :bind_service, 2)
|
341
341
|
|
342
342
|
when 'unbind-service', 'unbind_service'
|
343
|
-
usage('
|
343
|
+
usage('af unbind-service <servicename> <appname>')
|
344
344
|
set_cmd(:services, :unbind_service, 2)
|
345
345
|
|
346
346
|
when 'clone-services'
|
347
|
-
usage('
|
347
|
+
usage('af clone-services <src-app> <dest-app>')
|
348
348
|
set_cmd(:services, :clone_services, 2)
|
349
349
|
|
350
350
|
when 'aliases'
|
351
|
-
usage('
|
351
|
+
usage('af aliases')
|
352
352
|
set_cmd(:misc, :aliases)
|
353
353
|
|
354
354
|
when 'alias'
|
355
|
-
usage('
|
355
|
+
usage('af alias <alias[=]command>')
|
356
356
|
if @args.size == 1
|
357
357
|
set_cmd(:misc, :alias, 1)
|
358
358
|
elsif @args.size == 2
|
@@ -360,7 +360,7 @@ class VMC::Cli::Runner
|
|
360
360
|
end
|
361
361
|
|
362
362
|
when 'unalias'
|
363
|
-
usage('
|
363
|
+
usage('af unalias <alias>')
|
364
364
|
set_cmd(:misc, :unalias, 1)
|
365
365
|
|
366
366
|
when 'help'
|
data/lib/cli/version.rb
CHANGED
metadata
CHANGED
@@ -1,150 +1,116 @@
|
|
1
|
-
--- !ruby/object:Gem::Specification
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
2
|
name: af
|
3
|
-
version: !ruby/object:Gem::Version
|
4
|
-
|
5
|
-
|
6
|
-
- 0
|
7
|
-
- 3
|
8
|
-
- 12
|
9
|
-
- 2
|
10
|
-
version: 0.3.12.2
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
version: 0.3.12.3
|
5
|
+
prerelease:
|
11
6
|
platform: ruby
|
12
|
-
authors:
|
7
|
+
authors:
|
13
8
|
- AppFog
|
14
9
|
autorequire:
|
15
10
|
bindir: bin
|
16
11
|
cert_chain: []
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
dependencies:
|
21
|
-
- !ruby/object:Gem::Dependency
|
12
|
+
date: 2011-10-26 00:00:00.000000000Z
|
13
|
+
dependencies:
|
14
|
+
- !ruby/object:Gem::Dependency
|
22
15
|
name: json_pure
|
23
|
-
|
24
|
-
|
25
|
-
requirements:
|
16
|
+
requirement: &70217288887220 !ruby/object:Gem::Requirement
|
17
|
+
none: false
|
18
|
+
requirements:
|
26
19
|
- - ~>
|
27
|
-
- !ruby/object:Gem::Version
|
28
|
-
segments:
|
29
|
-
- 1
|
30
|
-
- 5
|
31
|
-
- 1
|
20
|
+
- !ruby/object:Gem::Version
|
32
21
|
version: 1.5.1
|
33
22
|
type: :runtime
|
34
|
-
version_requirements: *id001
|
35
|
-
- !ruby/object:Gem::Dependency
|
36
|
-
name: rubyzip2
|
37
23
|
prerelease: false
|
38
|
-
|
39
|
-
|
24
|
+
version_requirements: *70217288887220
|
25
|
+
- !ruby/object:Gem::Dependency
|
26
|
+
name: rubyzip2
|
27
|
+
requirement: &70217288886520 !ruby/object:Gem::Requirement
|
28
|
+
none: false
|
29
|
+
requirements:
|
40
30
|
- - ~>
|
41
|
-
- !ruby/object:Gem::Version
|
42
|
-
segments:
|
43
|
-
- 2
|
44
|
-
- 0
|
45
|
-
- 1
|
31
|
+
- !ruby/object:Gem::Version
|
46
32
|
version: 2.0.1
|
47
33
|
type: :runtime
|
48
|
-
version_requirements: *id002
|
49
|
-
- !ruby/object:Gem::Dependency
|
50
|
-
name: highline
|
51
34
|
prerelease: false
|
52
|
-
|
53
|
-
|
35
|
+
version_requirements: *70217288886520
|
36
|
+
- !ruby/object:Gem::Dependency
|
37
|
+
name: highline
|
38
|
+
requirement: &70217288869820 !ruby/object:Gem::Requirement
|
39
|
+
none: false
|
40
|
+
requirements:
|
54
41
|
- - ~>
|
55
|
-
- !ruby/object:Gem::Version
|
56
|
-
segments:
|
57
|
-
- 1
|
58
|
-
- 6
|
59
|
-
- 1
|
42
|
+
- !ruby/object:Gem::Version
|
60
43
|
version: 1.6.1
|
61
44
|
type: :runtime
|
62
|
-
version_requirements: *id003
|
63
|
-
- !ruby/object:Gem::Dependency
|
64
|
-
name: rest-client
|
65
45
|
prerelease: false
|
66
|
-
|
67
|
-
|
68
|
-
|
69
|
-
|
70
|
-
|
71
|
-
|
72
|
-
|
73
|
-
|
46
|
+
version_requirements: *70217288869820
|
47
|
+
- !ruby/object:Gem::Dependency
|
48
|
+
name: rest-client
|
49
|
+
requirement: &70217288868860 !ruby/object:Gem::Requirement
|
50
|
+
none: false
|
51
|
+
requirements:
|
52
|
+
- - ! '>='
|
53
|
+
- !ruby/object:Gem::Version
|
74
54
|
version: 1.6.1
|
75
55
|
- - <
|
76
|
-
- !ruby/object:Gem::Version
|
77
|
-
segments:
|
78
|
-
- 1
|
79
|
-
- 7
|
80
|
-
- 0
|
56
|
+
- !ruby/object:Gem::Version
|
81
57
|
version: 1.7.0
|
82
58
|
type: :runtime
|
83
|
-
version_requirements: *id004
|
84
|
-
- !ruby/object:Gem::Dependency
|
85
|
-
name: terminal-table
|
86
59
|
prerelease: false
|
87
|
-
|
88
|
-
|
60
|
+
version_requirements: *70217288868860
|
61
|
+
- !ruby/object:Gem::Dependency
|
62
|
+
name: terminal-table
|
63
|
+
requirement: &70217288867980 !ruby/object:Gem::Requirement
|
64
|
+
none: false
|
65
|
+
requirements:
|
89
66
|
- - ~>
|
90
|
-
- !ruby/object:Gem::Version
|
91
|
-
segments:
|
92
|
-
- 1
|
93
|
-
- 4
|
94
|
-
- 2
|
67
|
+
- !ruby/object:Gem::Version
|
95
68
|
version: 1.4.2
|
96
69
|
type: :runtime
|
97
|
-
version_requirements: *id005
|
98
|
-
- !ruby/object:Gem::Dependency
|
99
|
-
name: rake
|
100
70
|
prerelease: false
|
101
|
-
|
102
|
-
|
103
|
-
|
104
|
-
|
105
|
-
|
106
|
-
|
107
|
-
|
71
|
+
version_requirements: *70217288867980
|
72
|
+
- !ruby/object:Gem::Dependency
|
73
|
+
name: rake
|
74
|
+
requirement: &70217288867360 !ruby/object:Gem::Requirement
|
75
|
+
none: false
|
76
|
+
requirements:
|
77
|
+
- - ! '>='
|
78
|
+
- !ruby/object:Gem::Version
|
79
|
+
version: '0'
|
108
80
|
type: :development
|
109
|
-
version_requirements: *id006
|
110
|
-
- !ruby/object:Gem::Dependency
|
111
|
-
name: rspec
|
112
81
|
prerelease: false
|
113
|
-
|
114
|
-
|
82
|
+
version_requirements: *70217288867360
|
83
|
+
- !ruby/object:Gem::Dependency
|
84
|
+
name: rspec
|
85
|
+
requirement: &70217288866700 !ruby/object:Gem::Requirement
|
86
|
+
none: false
|
87
|
+
requirements:
|
115
88
|
- - ~>
|
116
|
-
- !ruby/object:Gem::Version
|
117
|
-
segments:
|
118
|
-
- 1
|
119
|
-
- 3
|
120
|
-
- 0
|
89
|
+
- !ruby/object:Gem::Version
|
121
90
|
version: 1.3.0
|
122
91
|
type: :development
|
123
|
-
version_requirements: *id007
|
124
|
-
- !ruby/object:Gem::Dependency
|
125
|
-
name: webmock
|
126
92
|
prerelease: false
|
127
|
-
|
128
|
-
|
93
|
+
version_requirements: *70217288866700
|
94
|
+
- !ruby/object:Gem::Dependency
|
95
|
+
name: webmock
|
96
|
+
requirement: &70217288866080 !ruby/object:Gem::Requirement
|
97
|
+
none: false
|
98
|
+
requirements:
|
129
99
|
- - ~>
|
130
|
-
- !ruby/object:Gem::Version
|
131
|
-
segments:
|
132
|
-
- 1
|
133
|
-
- 5
|
134
|
-
- 0
|
100
|
+
- !ruby/object:Gem::Version
|
135
101
|
version: 1.5.0
|
136
102
|
type: :development
|
137
|
-
|
103
|
+
prerelease: false
|
104
|
+
version_requirements: *70217288866080
|
138
105
|
description: AppFog.com CLI
|
139
106
|
email: support@appfog.com
|
140
|
-
executables:
|
107
|
+
executables:
|
141
108
|
- af
|
142
109
|
extensions: []
|
143
|
-
|
144
|
-
extra_rdoc_files:
|
110
|
+
extra_rdoc_files:
|
145
111
|
- README.md
|
146
112
|
- LICENSE
|
147
|
-
files:
|
113
|
+
files:
|
148
114
|
- LICENSE
|
149
115
|
- README.md
|
150
116
|
- Rakefile
|
@@ -188,35 +154,29 @@ files:
|
|
188
154
|
- spec/spec_helper.rb
|
189
155
|
- spec/unit/cli_opts_spec.rb
|
190
156
|
- spec/unit/client_spec.rb
|
191
|
-
|
157
|
+
- bin/af
|
192
158
|
homepage: http://appfog.com
|
193
159
|
licenses: []
|
194
|
-
|
195
160
|
post_install_message:
|
196
161
|
rdoc_options: []
|
197
|
-
|
198
|
-
require_paths:
|
162
|
+
require_paths:
|
199
163
|
- lib
|
200
|
-
required_ruby_version: !ruby/object:Gem::Requirement
|
201
|
-
|
202
|
-
|
203
|
-
|
204
|
-
|
205
|
-
|
206
|
-
|
207
|
-
|
208
|
-
requirements:
|
209
|
-
- -
|
210
|
-
- !ruby/object:Gem::Version
|
211
|
-
|
212
|
-
- 0
|
213
|
-
version: "0"
|
164
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
165
|
+
none: false
|
166
|
+
requirements:
|
167
|
+
- - ! '>='
|
168
|
+
- !ruby/object:Gem::Version
|
169
|
+
version: '0'
|
170
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
171
|
+
none: false
|
172
|
+
requirements:
|
173
|
+
- - ! '>='
|
174
|
+
- !ruby/object:Gem::Version
|
175
|
+
version: '0'
|
214
176
|
requirements: []
|
215
|
-
|
216
177
|
rubyforge_project:
|
217
|
-
rubygems_version: 1.
|
178
|
+
rubygems_version: 1.8.10
|
218
179
|
signing_key:
|
219
180
|
specification_version: 3
|
220
181
|
summary: AppFog.com CLI
|
221
182
|
test_files: []
|
222
|
-
|