spaceship 0.36.0 → 0.36.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: a7b5189c7d4d7c799d6627a99a2ed50813f2543f
4
- data.tar.gz: 0616e07763d76c59d9c85bedf0a24b5c1a14f720
3
+ metadata.gz: a6aafbcccfd89c24a209ac482adcf6350c96c14f
4
+ data.tar.gz: ac4cf5014924d61f16842f58f66202830f0a59da
5
5
  SHA512:
6
- metadata.gz: e2123061b94aa2545845a39731d6a5a2dd895b9264124ee1acf12638a9944dc640f0ea9003e4a694a237707084f441a3bd5d16d0ad0a4104aa5d9fe914a8a6d7
7
- data.tar.gz: aa301f95bfa87dd9bea5506ccaf672bd89433f22cebc6638f5475ed98b66b6c3adf27351be05b7c68edd583ff5c779395c29551b0c66c18957d309c2184b644e
6
+ metadata.gz: ada04897dbac634b6a070bedcd7ce4a105ae62590ddae77f2820859d3761ffa1c1e63a6eab506bef5e04a459234ac4de14661ab7400e5a22bbadc014b1db69fd
7
+ data.tar.gz: 817056e3cb61e43aa467a2a0c630ab20b9755ad60421b93970e53e7bef5148614d07bc3821c1f70d2c3bf7bb0d9f15fc9d1726ac6882e3aef549eb2ad9ceb4f4
data/README.md CHANGED
@@ -30,7 +30,6 @@
30
30
  [![Twitter: @FastlaneTools](https://img.shields.io/badge/contact-@KrauseFx-blue.svg?style=flat)](https://twitter.com/KrauseFx)
31
31
  [![License](http://img.shields.io/badge/license-MIT-green.svg?style=flat)](https://github.com/fastlane/fastlane/blob/master/spaceship/LICENSE)
32
32
  [![Gem](https://img.shields.io/gem/v/spaceship.svg?style=flat)](http://rubygems.org/gems/spaceship)
33
- [![Build Status](https://img.shields.io/circleci/project/fastlane/fastlane/master.svg?style=flat)](https://circleci.com/gh/fastlane/fastlane)
34
33
 
35
34
  `spaceship` exposes both the Apple Developer Center and the iTunes Connect API. This fast and powerful API powers parts of fastlane, and can be leveraged for more advanced fastlane features. Scripting your Developer Center workflow has never been easier!
36
35
 
@@ -48,7 +47,7 @@ Get in contact with the creators on Twitter: [@FastlaneTools](https://twitter.co
48
47
 
49
48
  -------
50
49
 
51
- <h5 align="center"><code>spaceship</code> is part of <a href="https://fastlane.tools">fastlane</a>: The easiest way to automate building and releasing your iOS and Android apps.</h5>
50
+ <h5 align="center"><code>spaceship</code> is part of <a href="https://fastlane.tools">fastlane</a>: The easiest way to automate beta deployments and releases for your iOS and Android apps.</h5>
52
51
 
53
52
  # What's spaceship?
54
53
 
@@ -123,7 +123,8 @@ module Spaceship
123
123
  else
124
124
  begin
125
125
  @attr_mapping ||= ancestors[1].attr_mapping
126
- rescue NameError, NoMethodError
126
+ rescue NoMethodError
127
+ rescue NameError
127
128
  end
128
129
  end
129
130
  return @attr_mapping
@@ -33,7 +33,7 @@ module Spaceship
33
33
  def remove_alpha_channel(original)
34
34
  path = "/tmp/#{Digest::MD5.hexdigest(original)}.png"
35
35
  FileUtils.copy(original, path)
36
- `sips -s format bmp '#{path}' &> /dev/null ` # &> /dev/null since there is warning because of the extension
36
+ `sips -s format bmp '#{path}' &> /dev/null` # &> /dev/null since there is warning because of the extension
37
37
  `sips -s format png '#{path}'`
38
38
  return path
39
39
  end
@@ -128,12 +128,12 @@ module Spaceship
128
128
  private
129
129
 
130
130
  def prefix_mzgenre(value)
131
- (value.include? "MZGenre") ? value : "MZGenre.#{value}"
131
+ value.include?("MZGenre") ? value : "MZGenre.#{value}"
132
132
  end
133
133
 
134
134
  def prefix_apps(value)
135
135
  return value unless value.include? "Stickers"
136
- (value.include? "Apps") ? value : "Apps.#{value}"
136
+ value.include?("Apps") ? value : "Apps.#{value}"
137
137
  end
138
138
  end
139
139
  end
@@ -304,6 +304,19 @@ module Spaceship
304
304
  setup_trailers
305
305
  end
306
306
 
307
+ # This method will generate the required keys/values
308
+ # for iTunes Connect to validate the uploaded image
309
+ def generate_image_metadata(image_data, original_file_name)
310
+ {
311
+ assetToken: image_data["token"],
312
+ originalFileName: original_file_name,
313
+ size: image_data["length"],
314
+ height: image_data["height"],
315
+ width: image_data["width"],
316
+ checksum: image_data["md5"]
317
+ }
318
+ end
319
+
307
320
  # Uploads or removes the large icon
308
321
  # @param icon_path (String): The path to the icon. Use nil to remove it
309
322
  def upload_large_icon!(icon_path)
@@ -314,7 +327,7 @@ module Spaceship
314
327
  upload_image = UploadFile.from_path icon_path
315
328
  image_data = client.upload_large_icon(self, upload_image)
316
329
 
317
- @large_app_icon.reset!({ asset_token: image_data['token'], original_file_name: upload_image.file_name })
330
+ raw_data["largeAppIcon"]["value"] = generate_image_metadata(image_data, upload_image.file_name)
318
331
  end
319
332
 
320
333
  # Uploads or removes the watch icon
@@ -327,7 +340,7 @@ module Spaceship
327
340
  upload_image = UploadFile.from_path icon_path
328
341
  image_data = client.upload_watch_icon(self, upload_image)
329
342
 
330
- @watch_app_icon.reset!({ asset_token: image_data["token"], original_file_name: upload_image.file_name })
343
+ raw_data["watchAppIcon"]["value"] = generate_image_metadata(image_data, upload_image.file_name)
331
344
  end
332
345
 
333
346
  # Uploads or removes the transit app file
@@ -1,4 +1,4 @@
1
1
  module Spaceship
2
- VERSION = "0.36.0".freeze
2
+ VERSION = "0.36.1".freeze
3
3
  DESCRIPTION = "Ruby library to access the Apple Dev Center and iTunes Connect".freeze
4
4
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: spaceship
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.36.0
4
+ version: 0.36.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Felix Krause
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2016-10-11 00:00:00.000000000 Z
12
+ date: 2016-10-21 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: credentials_manager
@@ -303,14 +303,14 @@ dependencies:
303
303
  requirements:
304
304
  - - "~>"
305
305
  - !ruby/object:Gem::Version
306
- version: 0.38.0
306
+ version: 0.44.0
307
307
  type: :development
308
308
  prerelease: false
309
309
  version_requirements: !ruby/object:Gem::Requirement
310
310
  requirements:
311
311
  - - "~>"
312
312
  - !ruby/object:Gem::Version
313
- version: 0.38.0
313
+ version: 0.44.0
314
314
  description: Ruby library to access the Apple Dev Center and iTunes Connect
315
315
  email:
316
316
  - spaceship@krausefx.com
@@ -400,7 +400,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
400
400
  version: '0'
401
401
  requirements: []
402
402
  rubyforge_project:
403
- rubygems_version: 2.5.1
403
+ rubygems_version: 2.2.2
404
404
  signing_key:
405
405
  specification_version: 4
406
406
  summary: Ruby library to access the Apple Dev Center and iTunes Connect