a2zdeploy 1.0.13 → 1.0.14

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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 3f05346bc3f5cea73f05b1649fa634d19abed1ae
4
- data.tar.gz: 535e19fb386f8a297144c6a0dbe3c7247c318297
3
+ metadata.gz: 962ccdc90dcbc06c4e658c55f4d7bb36a2dae4c1
4
+ data.tar.gz: d39518c574b3f8bb63794c50437cc9d50fd4802f
5
5
  SHA512:
6
- metadata.gz: 3badb1ab50f242f7197975f4caef07829e2ca3d1ad41831ec494e4c1af8662bc3fc3690256fd6f9b6da7313b9fac8fe8e5e834a2dd6818f334f336b931619d8c
7
- data.tar.gz: 6fa9b29b513dad46ca02f61f5cbd29ba99442c7bd71a43a8caea4c9c5563b4ed426c48eedf66337b4fa34f11761146e3956705c93b456c9f6eca845c14e07ea5
6
+ metadata.gz: 546607ce6d67293fee2fb49bb048da3f08e242cb7ee378f75cc1fa5bf67131041973670f7ea37fa7dbc0be1a6df90d497d2136ed696f07ba7a692e06c389b074
7
+ data.tar.gz: 58b91ebca39cbc2a107847c88e1bb59d7d0ebc778aba6184d6c13f062b02a3cb8275702676bd1c48a7ffd22333270c1a6ed8459393f03853329f88c9a5be6834
data/a2zdeploy.gemspec CHANGED
@@ -1,6 +1,6 @@
1
1
  Gem::Specification.new do |s|
2
2
  s.name = 'a2zdeploy'
3
- s.version = '1.0.13'
3
+ s.version = '1.0.14'
4
4
  s.date = '2016-02-08'
5
5
  s.summary = 'Given a project dependency chain, updates versions, builds, tests, manages service and cloud settings as well as build environment configuration'
6
6
  s.description = 'Automated Upgrades Gem. Provides version upgrades, build and deployment configuration management'
@@ -45,7 +45,7 @@ class InputValidator
45
45
  msg = @simple_validator.method_exists project, 'is_root'
46
46
  if msg.nil?
47
47
  msg = @simple_validator.method_value_not_nil_or_empty project, 'is_root'
48
- project.metadata.is_root = project.metadata.is_root.downcase == 'y' if msg.nil?
48
+ project.is_root = project.is_root.downcase == 'y' if msg.nil?
49
49
  else
50
50
  yield msg
51
51
  end
data/lib/upgrade.rb CHANGED
@@ -57,7 +57,7 @@ class Upgrade
57
57
 
58
58
  # TODO: Need to check if node has failed before invoking rollback
59
59
  if @rollback
60
- puts "Starting Rollback."
60
+ puts "Starting Rollback..."
61
61
  rollback = new Rollback @repo_url, 'origin', @branch, BACKUP_BRANCH, @config_map.metadata
62
62
  tag_creator = rollback.method(:create_rollback_tag)
63
63
  return false if !rollback.Do
@@ -195,7 +195,7 @@ class Upgrade
195
195
  doc = Nokogiri::XML File.read(file)
196
196
  nodes = doc.xpath "//*[@id]"
197
197
  nodes.each { |node|
198
- node['version'] = @versions[node['id']] if (@versions.has_key?(node['id']))
198
+ node['version'] = @versions[node['id']] if @versions.has_key?(node['id'])
199
199
  }
200
200
  File.write file, doc.to_xml
201
201
  }
@@ -265,9 +265,7 @@ class Upgrade
265
265
  name = path.split('\\')[2].split GlobalConstants::DOT
266
266
  name_without_ver = GlobalConstants::EMPTY
267
267
  name.all? {|i|
268
- if i.to_i == 0
269
- name_without_ver += i.to_s + GlobalConstants::DOT
270
- end
268
+ name_without_ver += i.to_s + GlobalConstants::DOT if i.to_i == 0
271
269
  }
272
270
  name_without_ver.chomp GlobalConstants::DOT
273
271
  end
@@ -293,9 +291,8 @@ class Upgrade
293
291
  else
294
292
  if @config_map.metadata.should_publish_nuget
295
293
  semver_file = @config_map.metadata.semver.file
296
- if (semver_file != nil && semver_file != GlobalConstants::EMPTY)
297
- semver_file.capitalize
298
- end
294
+ semver_file.capitalize if (semver_file != nil && semver_file != GlobalConstants::EMPTY)
295
+
299
296
  auto_update_semver @config_map.project_name, @config_map.metadata.semver.location, semver_file, @config_map.metadata.semver.dimension
300
297
  return true
301
298
  else
@@ -309,6 +306,7 @@ class Upgrade
309
306
  def update_version_map path
310
307
  path = File.join(Dir.pwd, path)
311
308
  nugets = Dir.glob path
309
+ versions = {}
312
310
  nugets.each { |nuget|
313
311
  full_name = File.basename nuget
314
312
  full_name = full_name.sub! '.nupkg', ''
data/lib/upgradeall.rb CHANGED
@@ -96,7 +96,7 @@ class UpgradeAll
96
96
 
97
97
  # save node name to use for status update
98
98
  node_name = node.project_name
99
- node_name = GlobalConstants::ROOT if (node.respond_to?('is_root') && node.is_root == 'true')
99
+ node_name = GlobalConstants::ROOT if (node.respond_to?('is_root') && node.is_root)
100
100
 
101
101
  # set project status in json
102
102
  if upgrade_status
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: a2zdeploy
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.13
4
+ version: 1.0.14
5
5
  platform: ruby
6
6
  authors:
7
7
  - Suresh Batta