travis-build-tools 2.0.46.0 → 2.0.48.0

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,15 +1,15 @@
1
1
  ---
2
2
  !binary "U0hBMQ==":
3
3
  metadata.gz: !binary |-
4
- M2NjMWE0NGFlNzg5N2U0YmNhYjI5MTBjOWZkY2E4OGQzYjNiODk5MQ==
4
+ MzNjMzZmMWIzMmU3ZDIzYWFiOTRjMjhiNWFhZDY5OTQ3ZGIxM2U0Yw==
5
5
  data.tar.gz: !binary |-
6
- MDAxZmY2ZmU3ZTY3MjlmNmE1MGUyYTIwYzAyYWQzMmIxZTIyY2NiMw==
6
+ ZDllNTE2NzI5NzQ3MDQwOGYzZjE5NTg1OWUzZDM0OGRmYmQ4NjdjNg==
7
7
  SHA512:
8
8
  metadata.gz: !binary |-
9
- NmMwMTFmMTI0ZTg3NThlZjJjZTBiZTYyYTBjMDZiOWRlOGE5MmU1ZGVhYzcy
10
- NzdkOWU5YjE4OTYwZjk5NGM1ODExYWIwMTc1YmZkYmIxMmYxZmE3MzQ0NjNk
11
- MWZmM2MxN2QzNzMzY2YwM2MwYmJiMmM3ZTA2OWZkNmRjZTgzYTA=
9
+ ZTMxN2VhZjcxMjM4Yzk2OTE4MzQ2YjcwYmI3NDE0ZTNmMTIyODIzODgyOWFi
10
+ NzlhMGNmYjdkNTI5YWU0YTA0ZjkwY2I0NjI3NzEzOWE1ZDEwMjhmYzYzNzU5
11
+ ODgwOTZhOTVhYjVkNDMyOTgzYjc3OGMxNWI5ZjkzMDQzMTVkYmY=
12
12
  data.tar.gz: !binary |-
13
- NjVmMzhjMjg1OGIyYzBiMTFlMGRlY2RiNWM3MWU0MGQ2YTYwODQwODJmNGYy
14
- MDdkMGViYzc2MzQ0ZTQzMGY3ZDFmYWFiZmRhYWM0MDg2N2RkZmFhMTExYzNi
15
- MzNlMzI3ODYxYzU2YzkwZGEyZTA3YzkyMjc5YjlmZWYzZTVmZjk=
13
+ NmZkMDE5MjljMGIxMjM1OTg0Y2I1MTI5NGZlZWQyNDc2MGFjYjU2NWZmMGVj
14
+ NzUzZTNiOGVkNTU0YWE4YWE1YTgyZjYzZTg0MGVmMjU2M2VjZGY3ZGMyODZj
15
+ ZGNlMzFhYjIzZjIyYjUzZDRhMDU3OTQ5OWFjMjAwZThmMzRmYmI=
@@ -3,10 +3,13 @@ module TravisBuildTools
3
3
  def initialize(service_user, git_repository = nil)
4
4
  @service_user = service_user
5
5
  origin_url = %x[git config --get remote.origin.url]
6
- @git_repository = git_repository || origin_url.split('://')[1] || origin_url.split('@')[1]
7
-
8
- raise 'git_repository is not specified' if !@git_repository
9
- raise 'service_user is not specified' if !@service_user
6
+ git_repository ||= origin_url.split('://')[1] || origin_url.split('@')[1]
7
+ raise 'git_repository is not specified' if !git_repository
8
+ raise 'service_user is not specified' if !service_user
9
+
10
+ #Set the service remote
11
+ puts %x[git remote add service https://#{service_user}@#{git_repository}]
12
+ puts %x[git fetch service]
10
13
  end
11
14
 
12
15
  def publish_git_tag(tag_name)
@@ -19,7 +22,7 @@ module TravisBuildTools
19
22
  puts %x[git tag #{tag_name} -a -m "Generated tag from TravisCI."]
20
23
  puts "Pushing Git tag #{tag_name}."
21
24
 
22
- %x[git push --tags --quiet https://#{@service_user}@#{@git_repository} #{tag_name} > /dev/null 2>&1]
25
+ %x[git push --tags --quiet service #{tag_name} > /dev/null 2>&1]
23
26
  end
24
27
  end
25
28
 
@@ -40,10 +43,10 @@ module TravisBuildTools
40
43
  next_branch_to_merge = (sorted_branches.drop_while{|b| b <= current_release_version}.map{|v| release_branch_name + v.to_s} + ['master']).first
41
44
 
42
45
  #create a merge commit for that branch
43
- puts %x[git merge --no-ff origin/#{next_branch_to_merge}]
46
+ puts %x[git merge --no-ff service/#{next_branch_to_merge} -m"Merge remote-tracking branch '#{ENV['TRAVIS_BRANCH']}'"]
44
47
  puts "Merging to downstream branch: #{next_branch_to_merge}"
45
48
  #push origin for that branch using the service user
46
- %x[git push --quiet https://#{@service_user}@#{@git_repository} HEAD:#{next_branch_to_merge} > /dev/null 2>&1]
49
+ %x[git push --quiet service HEAD:#{next_branch_to_merge} > /dev/null 2>&1]
47
50
  end
48
51
  end
49
52
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: travis-build-tools
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.0.46.0
4
+ version: 2.0.48.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Warren Parad