waz-cmd 0.3.0 → 0.4.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (3) hide show
  1. data/bin/waz +6 -6
  2. data/lib/waz-cmd/version.rb +1 -1
  3. metadata +15 -15
data/bin/waz CHANGED
@@ -453,15 +453,15 @@ command 'deploy' do |c|
453
453
  raise 'Package (.cspkg) is required' unless args[2]
454
454
  raise 'Configuration file (.cscfg) is required' unless args[3]
455
455
 
456
- if options.account.nil?
456
+ if options.deploymentAccount.nil?
457
457
  accounts = arrayize(make_call("services/storageservices", :get, options)['StorageServices']['StorageService'])
458
458
  raise 'Must have at least one storage account' unless accounts.length > 0
459
- options.account = accounts[0]['ServiceName']
459
+ options.deploymentAccount = accounts[0]['ServiceName']
460
460
  end
461
461
 
462
- key = make_call("services/storageservices/#{options.account}/keys", :get, options)['StorageService']['StorageServiceKeys']['Primary']
462
+ key = make_call("services/storageservices/#{options.deploymentAccount}/keys", :get, options)['StorageService']['StorageServiceKeys']['Primary']
463
463
 
464
- WAZ::Storage::Base.establish_connection!(:account_name => options.account, :access_key => key)
464
+ WAZ::Storage::Base.establish_connection!(:account_name => options.deploymentAccount, :access_key => key)
465
465
  begin
466
466
  container = WAZ::Blobs::Container.create('deployments')
467
467
  rescue
@@ -474,8 +474,8 @@ command 'deploy' do |c|
474
474
  blob = container.upload(URI::escape(name), f, 'application/octet-stream')
475
475
  end
476
476
 
477
- config = File.read(args[3])
478
- config = config[3..-1] if config[0..2].force_encoding('utf-8') == "\xEF\xBB\xBF".force_encoding('utf-8')
477
+ config = open(args[3], 'rt') { |f| f.read }
478
+ config = config[1..-1] if config[0].force_encoding('utf-8') == "\xEF\xBB\xBF".force_encoding('utf-8')
479
479
  begin
480
480
  make_call("services/hostedservices/#{args[0]}/deploymentslots/#{args[1]}", :post, options,
481
481
  Nokogiri::XML::Builder.new(:encoding => 'utf-8') { |xml|
@@ -1,5 +1,5 @@
1
1
  module Waz
2
2
  module Cmd
3
- VERSION = "0.3.0"
3
+ VERSION = "0.4.0"
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: waz-cmd
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.0
4
+ version: 0.4.0
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -9,11 +9,11 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2011-07-09 00:00:00.000000000Z
12
+ date: 2011-09-23 00:00:00.000000000Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: commander
16
- requirement: &19385100 !ruby/object:Gem::Requirement
16
+ requirement: &70218991603200 !ruby/object:Gem::Requirement
17
17
  none: false
18
18
  requirements:
19
19
  - - ! '>='
@@ -21,10 +21,10 @@ dependencies:
21
21
  version: '0'
22
22
  type: :runtime
23
23
  prerelease: false
24
- version_requirements: *19385100
24
+ version_requirements: *70218991603200
25
25
  - !ruby/object:Gem::Dependency
26
26
  name: tilt
27
- requirement: &19384716 !ruby/object:Gem::Requirement
27
+ requirement: &70218991602780 !ruby/object:Gem::Requirement
28
28
  none: false
29
29
  requirements:
30
30
  - - ! '>='
@@ -32,10 +32,10 @@ dependencies:
32
32
  version: '0'
33
33
  type: :runtime
34
34
  prerelease: false
35
- version_requirements: *19384716
35
+ version_requirements: *70218991602780
36
36
  - !ruby/object:Gem::Dependency
37
37
  name: crack
38
- requirement: &19384272 !ruby/object:Gem::Requirement
38
+ requirement: &70218991602360 !ruby/object:Gem::Requirement
39
39
  none: false
40
40
  requirements:
41
41
  - - ! '>='
@@ -43,10 +43,10 @@ dependencies:
43
43
  version: '0'
44
44
  type: :runtime
45
45
  prerelease: false
46
- version_requirements: *19384272
46
+ version_requirements: *70218991602360
47
47
  - !ruby/object:Gem::Dependency
48
48
  name: nokogiri
49
- requirement: &19383924 !ruby/object:Gem::Requirement
49
+ requirement: &70218991601940 !ruby/object:Gem::Requirement
50
50
  none: false
51
51
  requirements:
52
52
  - - ! '>='
@@ -54,10 +54,10 @@ dependencies:
54
54
  version: '0'
55
55
  type: :runtime
56
56
  prerelease: false
57
- version_requirements: *19383924
57
+ version_requirements: *70218991601940
58
58
  - !ruby/object:Gem::Dependency
59
59
  name: waz-storage
60
- requirement: &19383480 !ruby/object:Gem::Requirement
60
+ requirement: &70218991601520 !ruby/object:Gem::Requirement
61
61
  none: false
62
62
  requirements:
63
63
  - - ! '>='
@@ -65,10 +65,10 @@ dependencies:
65
65
  version: '0'
66
66
  type: :runtime
67
67
  prerelease: false
68
- version_requirements: *19383480
68
+ version_requirements: *70218991601520
69
69
  - !ruby/object:Gem::Dependency
70
70
  name: uuidtools
71
- requirement: &19382988 !ruby/object:Gem::Requirement
71
+ requirement: &70218991601100 !ruby/object:Gem::Requirement
72
72
  none: false
73
73
  requirements:
74
74
  - - ! '>='
@@ -76,7 +76,7 @@ dependencies:
76
76
  version: '0'
77
77
  type: :runtime
78
78
  prerelease: false
79
- version_requirements: *19382988
79
+ version_requirements: *70218991601100
80
80
  description: This gem allows you to perform most of the available operations in the
81
81
  Windows Azure Service Management API from a friendly commandline tool.
82
82
  email:
@@ -125,7 +125,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
125
125
  version: '0'
126
126
  requirements: []
127
127
  rubyforge_project:
128
- rubygems_version: 1.8.5
128
+ rubygems_version: 1.8.10
129
129
  signing_key:
130
130
  specification_version: 3
131
131
  summary: Command-line tool to manage Windows Azure applications and storage accounts.