fastlane 2.82.0.beta.20180217010002 → 2.82.0.beta.20180218010003
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/cert/lib/cert/options.rb +5 -1
- data/deliver/lib/deliver/options.rb +10 -2
- data/fastlane/lib/assets/ActionDetails.md.erb +5 -4
- data/fastlane/lib/fastlane/actions/add_git_tag.rb +1 -0
- data/fastlane/lib/fastlane/actions/app_store_build_number.rb +6 -2
- data/fastlane/lib/fastlane/actions/appaloosa.rb +3 -1
- data/fastlane/lib/fastlane/actions/appetize_viewing_url_generator.rb +1 -0
- data/fastlane/lib/fastlane/actions/automatic_code_signing.rb +1 -0
- data/fastlane/lib/fastlane/actions/backup_xcarchive.rb +1 -0
- data/fastlane/lib/fastlane/actions/commit_github_file.rb +1 -0
- data/fastlane/lib/fastlane/actions/crashlytics.rb +2 -0
- data/fastlane/lib/fastlane/actions/create_pull_request.rb +2 -0
- data/fastlane/lib/fastlane/actions/deploygate.rb +2 -0
- data/fastlane/lib/fastlane/actions/dotgpg_environment.rb +1 -0
- data/fastlane/lib/fastlane/actions/download_dsyms.rb +6 -2
- data/fastlane/lib/fastlane/actions/dsym_zip.rb +1 -0
- data/fastlane/lib/fastlane/actions/frame_screenshots.rb +2 -1
- data/fastlane/lib/fastlane/actions/get_ipa_info_plist_value.rb +2 -1
- data/fastlane/lib/fastlane/actions/github_api.rb +1 -0
- data/fastlane/lib/fastlane/actions/hockey.rb +7 -1
- data/fastlane/lib/fastlane/actions/install_on_device.rb +1 -0
- data/fastlane/lib/fastlane/actions/installr.rb +1 -0
- data/fastlane/lib/fastlane/actions/latest_testflight_build_number.rb +6 -2
- data/fastlane/lib/fastlane/actions/modify_services.rb +6 -2
- data/fastlane/lib/fastlane/actions/read_podspec.rb +1 -0
- data/fastlane/lib/fastlane/actions/register_device.rb +4 -1
- data/fastlane/lib/fastlane/actions/register_devices.rb +4 -1
- data/fastlane/lib/fastlane/actions/resign.rb +2 -0
- data/fastlane/lib/fastlane/actions/s3.rb +14 -6
- data/fastlane/lib/fastlane/actions/set_changelog.rb +6 -2
- data/fastlane/lib/fastlane/actions/set_github_release.rb +3 -1
- data/fastlane/lib/fastlane/actions/testfairy.rb +2 -0
- data/fastlane/lib/fastlane/actions/tryouts.rb +1 -0
- data/fastlane/lib/fastlane/actions/update_app_identifier.rb +3 -1
- data/fastlane/lib/fastlane/actions/update_info_plist.rb +1 -0
- data/fastlane/lib/fastlane/actions/update_project_code_signing.rb +4 -2
- data/fastlane/lib/fastlane/actions/update_project_provisioning.rb +1 -0
- data/fastlane/lib/fastlane/actions/update_project_team.rb +3 -1
- data/fastlane/lib/fastlane/actions/upload_symbols_to_crashlytics.rb +1 -0
- data/fastlane/lib/fastlane/actions/upload_symbols_to_sentry.rb +2 -0
- data/fastlane/lib/fastlane/actions/verify_xcode.rb +1 -0
- data/fastlane/lib/fastlane/actions/version_bump_podspec.rb +1 -0
- data/fastlane/lib/fastlane/actions/version_get_podspec.rb +1 -0
- data/fastlane/lib/fastlane/actions/xcode_install.rb +4 -2
- data/fastlane/lib/fastlane/documentation/actions_list.rb +7 -1
- data/fastlane/lib/fastlane/erb_template_helper.rb +8 -3
- data/fastlane/lib/fastlane/version.rb +1 -1
- data/fastlane_core/lib/fastlane_core/configuration/config_item.rb +8 -0
- data/frameit/lib/frameit/options.rb +2 -1
- data/gym/lib/gym/options.rb +2 -1
- data/match/lib/match/options.rb +6 -2
- data/pem/lib/pem/options.rb +6 -2
- data/pilot/lib/pilot/options.rb +10 -3
- data/precheck/lib/precheck/options.rb +6 -2
- data/produce/lib/produce/options.rb +9 -2
- data/scan/lib/scan/options.rb +4 -2
- data/screengrab/lib/screengrab/options.rb +6 -1
- data/sigh/lib/sigh/options.rb +6 -2
- data/snapshot/lib/snapshot/options.rb +6 -3
- data/spaceship/lib/spaceship/tunes/iap.rb +45 -0
- data/spaceship/lib/spaceship/tunes/iap_detail.rb +21 -1
- data/spaceship/lib/spaceship/tunes/iap_list.rb +7 -0
- data/spaceship/lib/spaceship/tunes/tunes_client.rb +18 -0
- data/supply/lib/supply/options.rb +9 -2
- metadata +2 -2
@@ -38,6 +38,10 @@ module Spaceship
|
|
38
38
|
# @return (Hash) subscription pricing target
|
39
39
|
attr_accessor :subscription_price_target
|
40
40
|
|
41
|
+
# @return (Hash) Relevant only for recurring subscriptions. Holds pricing related data, such
|
42
|
+
# as subscription pricing, intro offers, etc.
|
43
|
+
attr_accessor :raw_pricing_data
|
44
|
+
|
41
45
|
attr_mapping({
|
42
46
|
'adamId' => :purchase_id,
|
43
47
|
'referenceName.value' => :reference_name,
|
@@ -48,6 +52,15 @@ module Spaceship
|
|
48
52
|
'clearedForSale.value' => :cleared_for_sale
|
49
53
|
})
|
50
54
|
|
55
|
+
def setup
|
56
|
+
@raw_pricing_data = @raw_data["pricingData"]
|
57
|
+
@raw_data.delete("pricingData")
|
58
|
+
|
59
|
+
if @raw_pricing_data
|
60
|
+
@raw_data.set(["pricingIntervals"], @raw_pricing_data["subscriptions"])
|
61
|
+
end
|
62
|
+
end
|
63
|
+
|
51
64
|
# @return (Hash) Hash of languages
|
52
65
|
# @example: {
|
53
66
|
# 'de-DE': {
|
@@ -104,6 +117,7 @@ module Spaceship
|
|
104
117
|
}
|
105
118
|
end
|
106
119
|
raw_data.set(["pricingIntervals"], new_intervals)
|
120
|
+
@raw_pricing_data["subscriptions"] = new_intervals if @raw_pricing_data
|
107
121
|
end
|
108
122
|
|
109
123
|
# @return (Array) pricing intervals
|
@@ -117,7 +131,7 @@ module Spaceship
|
|
117
131
|
# }
|
118
132
|
# ]
|
119
133
|
def pricing_intervals
|
120
|
-
@pricing_intervals ||= raw_data["pricingIntervals"].map do |interval|
|
134
|
+
@pricing_intervals ||= (raw_data["pricingIntervals"] || []).map do |interval|
|
121
135
|
{
|
122
136
|
tier: interval["value"]["tierStem"].to_i,
|
123
137
|
begin_date: interval["value"]["priceTierEffectiveDate"],
|
@@ -201,6 +215,12 @@ module Spaceship
|
|
201
215
|
end
|
202
216
|
# Update the Purchase
|
203
217
|
client.update_iap!(app_id: application.apple_id, purchase_id: self.purchase_id, data: raw_data)
|
218
|
+
|
219
|
+
# Update pricing for a recurring subscription.
|
220
|
+
if raw_data["addOnType"] == Spaceship::Tunes::IAPType::RECURRING
|
221
|
+
client.update_recurring_iap_pricing!(app_id: application.apple_id, purchase_id: self.purchase_id,
|
222
|
+
pricing_intervals: raw_data["pricingIntervals"])
|
223
|
+
end
|
204
224
|
end
|
205
225
|
|
206
226
|
# Deletes In-App-Purchase
|
@@ -58,6 +58,13 @@ module Spaceship
|
|
58
58
|
def edit
|
59
59
|
attrs = client.load_iap(app_id: application.apple_id, purchase_id: self.purchase_id)
|
60
60
|
attrs[:application] = application
|
61
|
+
|
62
|
+
if attrs["addOnType"] == Spaceship::Tunes::IAPType::RECURRING
|
63
|
+
raw_pricing_data = client.load_recurring_iap_pricing(app_id: application.apple_id,
|
64
|
+
purchase_id: self.purchase_id)
|
65
|
+
attrs["pricingData"] = raw_pricing_data
|
66
|
+
end
|
67
|
+
|
61
68
|
Tunes::IAPDetail.new(attrs)
|
62
69
|
end
|
63
70
|
|
@@ -1103,6 +1103,24 @@ module Spaceship
|
|
1103
1103
|
end
|
1104
1104
|
end
|
1105
1105
|
|
1106
|
+
def update_recurring_iap_pricing!(app_id: nil, purchase_id: nil, pricing_intervals: nil)
|
1107
|
+
with_tunes_retry do
|
1108
|
+
r = request(:post) do |req|
|
1109
|
+
pricing_data = {}
|
1110
|
+
req.url("ra/apps/#{app_id}/iaps/#{purchase_id}/pricing/subscriptions")
|
1111
|
+
pricing_data["subscriptions"] = pricing_intervals
|
1112
|
+
req.body = pricing_data.to_json
|
1113
|
+
req.headers['Content-Type'] = 'application/json'
|
1114
|
+
end
|
1115
|
+
handle_itc_response(r.body)
|
1116
|
+
end
|
1117
|
+
end
|
1118
|
+
|
1119
|
+
def load_recurring_iap_pricing(app_id: nil, purchase_id: nil)
|
1120
|
+
r = request(:get, "ra/apps/#{app_id}/iaps/#{purchase_id}/pricing")
|
1121
|
+
parse_response(r, 'data')
|
1122
|
+
end
|
1123
|
+
|
1106
1124
|
def create_iap_family(app_id: nil, name: nil, product_id: nil, reference_name: nil, versions: [])
|
1107
1125
|
r = request(:get, "ra/apps/#{app_id}/iaps/family/template")
|
1108
1126
|
data = parse_response(r, 'data')
|
@@ -12,7 +12,8 @@ module Supply
|
|
12
12
|
short_option: "-p",
|
13
13
|
description: "The package name of the application to use",
|
14
14
|
code_gen_sensitive: true,
|
15
|
-
default_value: CredentialsManager::AppfileConfig.try_fetch_value(:package_name)
|
15
|
+
default_value: CredentialsManager::AppfileConfig.try_fetch_value(:package_name),
|
16
|
+
default_value_dynamic: true),
|
16
17
|
FastlaneCore::ConfigItem.new(key: :track,
|
17
18
|
short_option: "-a",
|
18
19
|
env_name: "SUPPLY_TRACK",
|
@@ -36,7 +37,8 @@ module Supply
|
|
36
37
|
short_option: "-m",
|
37
38
|
optional: true,
|
38
39
|
description: "Path to the directory containing the metadata files",
|
39
|
-
default_value: (Dir["./fastlane/metadata/android"] + Dir["./metadata"]).first
|
40
|
+
default_value: (Dir["./fastlane/metadata/android"] + Dir["./metadata"]).first,
|
41
|
+
default_value_dynamic: true),
|
40
42
|
FastlaneCore::ConfigItem.new(key: :key,
|
41
43
|
env_name: "SUPPLY_KEY",
|
42
44
|
short_option: "-k",
|
@@ -45,6 +47,7 @@ module Supply
|
|
45
47
|
description: "The p12 File used to authenticate with Google",
|
46
48
|
code_gen_sensitive: true,
|
47
49
|
default_value: Dir["*.p12"].first || CredentialsManager::AppfileConfig.try_fetch_value(:keyfile),
|
50
|
+
default_value_dynamic: true,
|
48
51
|
verify_block: proc do |value|
|
49
52
|
UI.user_error!("Could not find p12 file at path '#{File.expand_path(value)}'") unless File.exist?(File.expand_path(value))
|
50
53
|
end),
|
@@ -56,6 +59,7 @@ module Supply
|
|
56
59
|
description: "The issuer of the p12 file (email address of the service account)",
|
57
60
|
code_gen_sensitive: true,
|
58
61
|
default_value: CredentialsManager::AppfileConfig.try_fetch_value(:issuer),
|
62
|
+
default_value_dynamic: true,
|
59
63
|
verify_block: proc do |value|
|
60
64
|
UI.important("DEPRECATED --issuer OPTION. Use --json_key instead")
|
61
65
|
end),
|
@@ -67,6 +71,7 @@ module Supply
|
|
67
71
|
description: "The service account json file used to authenticate with Google",
|
68
72
|
code_gen_sensitive: true,
|
69
73
|
default_value: CredentialsManager::AppfileConfig.try_fetch_value(:json_key_file),
|
74
|
+
default_value_dynamic: true,
|
70
75
|
verify_block: proc do |value|
|
71
76
|
UI.user_error!("'#{value}' doesn't seem to be a JSON file") unless FastlaneCore::Helper.json_file?(File.expand_path(value))
|
72
77
|
UI.user_error!("Could not find service account json file at path '#{File.expand_path(value)}'") unless File.exist?(File.expand_path(value))
|
@@ -79,6 +84,7 @@ module Supply
|
|
79
84
|
description: "The service account json used to authenticate with Google",
|
80
85
|
code_gen_sensitive: true,
|
81
86
|
default_value: CredentialsManager::AppfileConfig.try_fetch_value(:json_key_data_raw),
|
87
|
+
default_value_dynamic: true,
|
82
88
|
verify_block: proc do |value|
|
83
89
|
begin
|
84
90
|
JSON.parse(value)
|
@@ -93,6 +99,7 @@ module Supply
|
|
93
99
|
conflicting_options: [:apk_paths],
|
94
100
|
code_gen_sensitive: true,
|
95
101
|
default_value: Dir["*.apk"].last || Dir[File.join("app", "build", "outputs", "apk", "app-Release.apk")].last,
|
102
|
+
default_value_dynamic: true,
|
96
103
|
optional: true,
|
97
104
|
verify_block: proc do |value|
|
98
105
|
UI.user_error!("Could not find apk file at path '#{value}'") unless File.exist?(value)
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: fastlane
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.82.0.beta.
|
4
|
+
version: 2.82.0.beta.20180218010003
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Olivier Halligon
|
@@ -25,7 +25,7 @@ authors:
|
|
25
25
|
autorequire:
|
26
26
|
bindir: bin
|
27
27
|
cert_chain: []
|
28
|
-
date: 2018-02-
|
28
|
+
date: 2018-02-18 00:00:00.000000000 Z
|
29
29
|
dependencies:
|
30
30
|
- !ruby/object:Gem::Dependency
|
31
31
|
name: slack-notifier
|