fastlane-plugin-validate_app 0.1.0 → 0.2.0
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:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 72c3a22f09166d36795a608b4dab6c4ace6ed3b1
|
4
|
+
data.tar.gz: 9296a0b40d77fbb60944fd7f5bdef51f985e70ab
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: cd2e62471bee904b5b98d49ded36fc536446ba37001b6d378b634e6f90678521ab30842bf76103d0df1390dd8481e7a7ba3baf42c2dad0b6b6cc7893414c54a6
|
7
|
+
data.tar.gz: 65c489b4566325b1bb8b3c5ede7b3b9526c2d065819b56cba3b4c91559355c7bc29ff9658ea4ae296f6eeb53eef8fe466d33490d211effa796ba8d6d7791b27a
|
data/README.md
CHANGED
@@ -1,6 +1,7 @@
|
|
1
1
|
# validate_app plugin
|
2
2
|
|
3
3
|
[![fastlane Plugin Badge](https://rawcdn.githack.com/fastlane/fastlane/master/fastlane/assets/plugin-badge.svg)](https://rubygems.org/gems/fastlane-plugin-validate_app)
|
4
|
+
[![CircleCI](https://circleci.com/gh/thii/fastlane-plugin-validate_app.svg?style=svg)](https://circleci.com/gh/thii/fastlane-plugin-validate_app)
|
4
5
|
|
5
6
|
## Getting Started
|
6
7
|
|
@@ -20,7 +21,7 @@ Appfile and password from yoru Keychain. You may specify a password directly or
|
|
20
21
|
pass it via `FASTLANE_PASSWORD` or `DELIVER_PASSWORD` environment variables.
|
21
22
|
Your password will not be printed out to build console log.
|
22
23
|
|
23
|
-
Returns
|
24
|
+
Returns `nil` if build is valid, and an array of error objects if
|
24
25
|
build is invalid
|
25
26
|
|
26
27
|
## Example
|
@@ -30,7 +31,7 @@ errors = validate_app(
|
|
30
31
|
ipa: "YourApp.ipa"
|
31
32
|
)
|
32
33
|
|
33
|
-
if errors.
|
34
|
+
if errors.nil?
|
34
35
|
upload_to_testflight
|
35
36
|
else
|
36
37
|
UI.user_error! "IPA file did not pass validation."
|
@@ -10,9 +10,8 @@ module Fastlane
|
|
10
10
|
xcode_contents_path = `dirname "$(xcode-select --print-path)"`.strip
|
11
11
|
altool = "#{xcode_contents_path}/Applications/Application Loader.app/Contents/Frameworks/ITunesSoftwareService.framework/Support/altool".shellescape
|
12
12
|
|
13
|
-
UI.message
|
13
|
+
UI.message("Validating your app. This may take a while.")
|
14
14
|
|
15
|
-
username = params[:username]
|
16
15
|
password = "@env:DELIVER_PASSWORD" if ENV["DELIVER_PASSWORD"].to_s.length > 0
|
17
16
|
password = "@env:FASTLANE_PASSWORD" if ENV["FASTLANE_PASSWORD"].to_s.length > 0
|
18
17
|
|
@@ -23,22 +22,22 @@ module Fastlane
|
|
23
22
|
command = [altool]
|
24
23
|
command << "--validate-app"
|
25
24
|
command << "--file"
|
26
|
-
command <<
|
25
|
+
command << params[:ipa].to_s.shellescape
|
27
26
|
command << "--username #{params[:username]}"
|
28
27
|
command << "--password"
|
29
28
|
command << password
|
30
29
|
command << "--output-format xml"
|
31
30
|
|
32
|
-
plist = Plist.parse_xml
|
31
|
+
plist = Plist.parse_xml(`#{command.join(' ')}`)
|
33
32
|
errors = plist["product-errors"]
|
34
33
|
|
35
34
|
if errors.empty?
|
36
|
-
UI.success
|
37
|
-
return
|
35
|
+
UI.success("Build is valid. Ready to be uploaded to iTunes Connect!")
|
36
|
+
return nil
|
38
37
|
end
|
39
38
|
|
40
39
|
errors.each do |error|
|
41
|
-
UI.error
|
40
|
+
UI.error(error["message"])
|
42
41
|
end
|
43
42
|
|
44
43
|
errors
|
@@ -53,7 +52,7 @@ module Fastlane
|
|
53
52
|
end
|
54
53
|
|
55
54
|
def self.return_value
|
56
|
-
"Returns
|
55
|
+
"Returns nil if build is valid, and an array of error objects if build is invalid"
|
57
56
|
end
|
58
57
|
|
59
58
|
def self.details
|