produce 0.5.1 → 0.6.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,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 09e15e363ff28b03b784fb3cd243a463022ea492
4
- data.tar.gz: 9b7198eba6f20ae61cd08d64e09bae8a190f939e
3
+ metadata.gz: 93cc031b37e351db3b6af36a95dc165bf9c57a4a
4
+ data.tar.gz: 10bf2aad9349613fa910b4e74253c2d47ac1175e
5
5
  SHA512:
6
- metadata.gz: 8c45ecbe6c6513cdd3fa63860dea91d6c0ebb8696ceddf5b453d8f8311f6a94b3f31a624232c9dadce0e5b43fe51ffca23334557b6c84f745b855da74d91f16b
7
- data.tar.gz: c54c4ce496d1b885c1776e3816e9a63b1d511b393d0592d08bf4e03330e956e329244d3da143cebd214fb39212fcfceb0e77910f006af7d2a033f637188f86d7
6
+ metadata.gz: 4ab86cf7c202be714a6ff6ea56e6a0f90d8f0a10f9a116686807492560e9099e39a6385146602754d89b813ef3e2ef372a3c75f9a419de70d91ec06b65c5cdd6
7
+ data.tar.gz: 99cfc5623466c9135586bccc0917ae1a57aa60ba8fe31db4daca1723e4107251be799fd94993280f8253f795e5e07dd798c0a7ae8db54bd9e1105822f1e97a01
data/README.md CHANGED
@@ -6,12 +6,12 @@
6
6
  </a>
7
7
  </h3>
8
8
  <p align="center">
9
- <a href="https://github.com/KrauseFx/deliver">deliver</a> &bull;
10
- <a href="https://github.com/KrauseFx/snapshot">snapshot</a> &bull;
11
- <a href="https://github.com/KrauseFx/frameit">frameit</a> &bull;
12
- <a href="https://github.com/KrauseFx/PEM">PEM</a> &bull;
13
- <a href="https://github.com/KrauseFx/sigh">sigh</a> &bull;
14
- <b>produce</b> &bull;
9
+ <a href="https://github.com/KrauseFx/deliver">deliver</a> &bull;
10
+ <a href="https://github.com/KrauseFx/snapshot">snapshot</a> &bull;
11
+ <a href="https://github.com/KrauseFx/frameit">frameit</a> &bull;
12
+ <a href="https://github.com/KrauseFx/PEM">PEM</a> &bull;
13
+ <a href="https://github.com/KrauseFx/sigh">sigh</a> &bull;
14
+ <b>produce</b> &bull;
15
15
  <a href="https://github.com/KrauseFx/cert">cert</a> &bull;
16
16
  <a href="https://github.com/KrauseFx/codes">codes</a> &bull;
17
17
  <a href="https://github.com/fastlane/spaceship">spaceship</a> &bull;
@@ -41,11 +41,11 @@ Get in contact with the developer on Twitter: [@KrauseFx](https://twitter.com/Kr
41
41
 
42
42
  -------
43
43
  <p align="center">
44
- <a href="#features">Features</a> &bull;
45
- <a href="#installation">Installation</a> &bull;
46
- <a href="#usage">Usage</a> &bull;
47
- <a href="#how-does-it-work">How does it work?</a> &bull;
48
- <a href="#tips">Tips</a> &bull;
44
+ <a href="#features">Features</a> &bull;
45
+ <a href="#installation">Installation</a> &bull;
46
+ <a href="#usage">Usage</a> &bull;
47
+ <a href="#how-does-it-work">How does it work?</a> &bull;
48
+ <a href="#tips">Tips</a> &bull;
49
49
  <a href="#need-help">Need help?</a>
50
50
  </p>
51
51
 
@@ -57,6 +57,9 @@ Get in contact with the developer on Twitter: [@KrauseFx](https://twitter.com/Kr
57
57
  # Features
58
58
 
59
59
  - **Create** new apps on both iTunes Connect and the Apple Developer Portal
60
+ - **Modify** Application Services on the Apple Developer Portal
61
+ - **Create** App Groups on the Apple Developer Portal
62
+ - **Associate** apps with App Groups on the Apple Developer Portal
60
63
  - Support for **multiple Apple accounts**, storing your credentials securely in the Keychain
61
64
 
62
65
  ##### [Like this tool? Be the first to know about updates and new fastlane tools](https://tinyletter.com/krausefx)
@@ -66,14 +69,51 @@ Get in contact with the developer on Twitter: [@KrauseFx](https://twitter.com/Kr
66
69
 
67
70
  # Usage
68
71
 
72
+ ## Creating a new application
73
+
69
74
  produce
70
-
71
- # Parameters
72
75
 
73
- Get the latest list of all available parameters;
76
+ To get a list of all available parameters:
74
77
 
75
78
  produce --help
76
79
 
80
+ ```
81
+ -u, --username STRING Your Apple ID Username (PRODUCE_USERNAME)
82
+ -a, --app_identifier STRING App Identifier (Bundle ID, e.g. com.krausefx.app) (PRODUCE_APP_IDENTIFIER)
83
+ -b, --bundle_identifier_suffix STRING App Identifier Suffix (Ignored if App Identifier does not ends with .*)
84
+ (PRODUCE_APP_IDENTIFIER_SUFFIX)
85
+ -q, --app_name STRING App Name (PRODUCE_APP_NAME)
86
+ -z, --app_version STRING Initial version number (e.g. '1.0') (PRODUCE_VERSION)
87
+ -s, --sku SKU Number (e.g. '1234') (PRODUCE_SKU)
88
+ -m, --language STRING Primary Language (e.g. 'English', 'German') (PRODUCE_LANGUAGE)
89
+ -c, --company_name STRING The name of your comapny. Only required if it's the first app you create
90
+ (PRODUCE_COMPANY_NAME)
91
+ -i, --skip_itc Skip the creation of the app on iTunes Connect (PRODUCE_SKIP_ITC)
92
+ -d, --skip_devcenter Skip the creation of the app on the Apple Developer Portal (PRODUCE_SKIP_DEVCENTER)
93
+ -t, --team_id STRING The ID of your team if you're in multiple teams (PRODUCE_TEAM_ID)
94
+ -l, --team_name STRING The name of your team if you're in multiple teams (PRODUCE_TEAM_NAME)
95
+ ```
96
+
97
+ ## Enabling / Disabling Application Services
98
+
99
+ If you want to enable Application Services for an App ID (HomeKit and HealthKit in this example):
100
+
101
+ produce enable_services --homekit --healthkit
102
+
103
+ If you want to disable Application Servies for an App ID (iCloud in this case):
104
+
105
+ produce disable_services --icloud
106
+
107
+ If you want to create a new App Group:
108
+
109
+ produce group -g group.krausefx -n "Example App Group"
110
+
111
+ If you want to associate an app with an App Group:
112
+
113
+ produce associate_group -a com.krausefx.app group.krausefx
114
+
115
+ # Parameters
116
+
77
117
  ```
78
118
  -u, --username STRING Your Apple ID Username (PRODUCE_USERNAME)
79
119
  -a, --app_identifier STRING App Identifier (Bundle ID, e.g. com.krausefx.app) (PRODUCE_APP_IDENTIFIER)
@@ -90,19 +130,55 @@ Get the latest list of all available parameters;
90
130
  -v, --version Display version information
91
131
  ```
92
132
 
133
+ Get a list of all available options using
134
+
135
+ produce enable_services --help
136
+
137
+ ```
138
+ --app-group Enable App Groups
139
+ --associated-domains Enable Associated Domains
140
+ --data-protection STRING Enable Data Protection, suitable values are "complete", "unlessopen" and "untilfirstauth"
141
+ --healthkit Enable HealthKit
142
+ --homekit Enable HomeKit
143
+ --wireless-conf Enable Wireless Accessory Configuration
144
+ --icloud STRING Enable iCloud, suitable values are "legacy" and "cloudkit"
145
+ --inter-app-audio Enable Inter-App-Audio
146
+ --passbook Enable Passbook
147
+ --push-notification Enable Push notification (only enables the service, does not configure certificates)
148
+ --vpn-conf Enable VPN Configuration
149
+ ```
150
+
151
+ produce disable_services --help
152
+
153
+ ```
154
+ --app-group Disable App Groups
155
+ --associated-domains Disable Associated Domains
156
+ --data-protection Disable Data Protection
157
+ --healthkit Disable HealthKit
158
+ --homekit Disable HomeKit
159
+ --wireless-conf Disable Wireless Accessory Configuration
160
+ --icloud Disable iCloud
161
+ --inter-app-audio Disable Inter-App-Audio
162
+ --passbook Disable Passbook
163
+ --push-notification Disable Push notifications
164
+ --vpn-conf Disable VPN Configuration
165
+ ```
166
+
93
167
  ## Environment Variables
94
168
  In case you want to pass more information to `produce` using environment variables:
95
169
 
96
170
  - `PRODUCE_USERNAME` (your iTunes Connect username)
97
171
  - `PRODUCE_APP_IDENTIFIER` (the bundle identifier of the new app)
98
172
  - `PRODUCE_APP_NAME` (the name of the new app)
173
+ - `PRODUCE_GROUP_IDENTIFIER` (the group identifier of the new app group)
174
+ - `PRODUCE_GROUP_NAME` (the name of the new app group)
99
175
  - `PRODUCE_LANGUAGE` (the language you want your app to use, e.g. `English`, `German`)
100
176
  - `PRODUCE_VERSION` (the initial app version)
101
177
  - `PRODUCE_SKU` (the SKU you want to use, which must be a unique number)
102
178
  - `PRODUCE_SKIP_ITC` (should iTunes Connect app be created)
103
179
  - `PRODUCE_SKIP_DEVCENTER` (should Apple Developer Portal app be created)
104
180
  - `PRODUCE_TEAM_ID` (the Team ID, e.g. `Q2CBPK58CA`)
105
- - `PRODUCE_TEAM_NAME` (the Team Name, e.g. `Felix Krause`)
181
+ - `PRODUCE_TEAM_NAME` (the Team Name, e.g. `Felix Krause`)
106
182
 
107
183
 
108
184
  ## [`fastlane`](https://github.com/KrauseFx/fastlane) Integration
@@ -150,7 +226,7 @@ You'll still have to fill out the remaining information (like screenshots, app d
150
226
  - [`codes`](https://github.com/KrauseFx/codes): Create promo codes for iOS Apps using the command line
151
227
  - [`spaceship`](https://github.com/fastlane/spaceship): Ruby library to access the Apple Dev Center and iTunes Connect
152
228
  - [`pilot`](https://github.com/fastlane/pilot): The best way to manage your TestFlight testers and builds from your terminal
153
- - [`boarding`](https://github.com/fastlane/boarding): The easiest way to invite your TestFlight beta testers
229
+ - [`boarding`](https://github.com/fastlane/boarding): The easiest way to invite your TestFlight beta testers
154
230
 
155
231
  ##### [Like this tool? Be the first to know about updates and new fastlane tools](https://tinyletter.com/krausefx)
156
232
 
data/bin/produce CHANGED
@@ -35,6 +35,90 @@ class ProduceApplication
35
35
  end
36
36
  end
37
37
 
38
+ command :enable_services do |c|
39
+ c.syntax = 'produce enable_services -a APP_IDENTIFIER SERVICE1, SERVICE2, ...'
40
+ c.description = 'Enable specific Application Services for a specific app on the Apple Developer Portal'
41
+ c.example 'Enable HealthKit, HomeKit and Passbook', 'produce enable_services -a com.example.app --healthkit --homekit --passbook'
42
+
43
+ c.option '--app-group', 'Enable App Groups'
44
+ c.option '--associated-domains', 'Enable Associated Domains'
45
+ c.option '--data-protection STRING', String, 'Enable Data Protection, suitable values are "complete", "unlessopen" and "untilfirstauth"'
46
+ c.option '--healthkit', 'Enable HealthKit'
47
+ c.option '--homekit', 'Enable HomeKit'
48
+ c.option '--wireless-conf', 'Enable Wireless Accessory Configuration'
49
+ c.option '--icloud STRING', String, 'Enable iCloud, suitable values are "legacy" and "cloudkit"'
50
+ c.option '--inter-app-audio', 'Enable Inter-App-Audio'
51
+ c.option '--passbook', 'Enable Passbook'
52
+ c.option '--push-notification', 'Enable Push notification (only enables the service, does not configure certificates)'
53
+ c.option '--vpn-conf', 'Enable VPN Configuration'
54
+
55
+ c.action do |args, options|
56
+ # Filter the options so that we can still build the configuration
57
+ allowed_keys = Produce::Options.available_options.collect { |config| config.key }
58
+ Produce.config = FastlaneCore::Configuration.create(Produce::Options.available_options, options.__hash__.select { |key, value| allowed_keys.include? key })
59
+
60
+ require 'produce/service'
61
+ Produce::Service.enable(options, args)
62
+ end
63
+ end
64
+
65
+ command :disable_services do |c|
66
+ c.syntax = 'produce disable_services -a APP_IDENTIFIER SERVICE1, SERVICE2, ...'
67
+ c.description = 'Disable specific Application Services for a specific app on the Apple Developer Portal'
68
+ c.example 'Disable HealthKit', 'produce disable_services -a com.example.app --healthkit'
69
+
70
+ c.option '--app-group', 'Disable App Groups'
71
+ c.option '--associated-domains', 'Disable Associated Domains'
72
+ c.option '--data-protection', 'Disable Data Protection'
73
+ c.option '--healthkit', 'Disable HealthKit'
74
+ c.option '--homekit', 'Disable HomeKit'
75
+ c.option '--wireless-conf', 'Disable Wireless Accessory Configuration'
76
+ c.option '--icloud', 'Disable iCloud'
77
+ c.option '--inter-app-audio', 'Disable Inter-App-Audio'
78
+ c.option '--passbook', 'Disable Passbook'
79
+ c.option '--push-notification', 'Disable Push notifications'
80
+ c.option '--vpn-conf', 'Disable VPN Configuration'
81
+
82
+ c.action do |args, options|
83
+ # Filter the options so that we can still build the configuration
84
+ allowed_keys = Produce::Options.available_options.collect { |config| config.key }
85
+ Produce.config = FastlaneCore::Configuration.create(Produce::Options.available_options, options.__hash__.select { |key, value| allowed_keys.include? key })
86
+
87
+ require 'produce/service'
88
+ Produce::Service.disable(options, args)
89
+ end
90
+ end
91
+
92
+ command :group do |c|
93
+ c.syntax = 'produce group'
94
+ c.description = 'Ensure that a specific App Group exists'
95
+ c.example 'Create group', 'produce group -g group.example.app -n "Example App Group"'
96
+
97
+ c.option '-n', '--group_name STRING', String, 'Name for the group that is created (PRODUCE_GROUP_NAME)'
98
+ c.option '-g', '--group_identifier STRING', String, 'Group identifier for the group (PRODUCE_GROUP_IDENTIFIER)'
99
+
100
+ c.action do |args, options|
101
+ allowed_keys = Produce::Options.available_options.collect { |config| config.key }
102
+ Produce.config = FastlaneCore::Configuration.create(Produce::Options.available_options, options.__hash__.select { |key, value| allowed_keys.include? key })
103
+
104
+ require 'produce/group'
105
+ Produce::Group.new.create(options, args)
106
+ end
107
+ end
108
+
109
+ command :associate_group do |c|
110
+ c.syntax = 'produce associate_group -a APP_IDENTIFIER GROUP_IDENTIFIER1, GROUP_IDENTIFIER2, ...'
111
+ c.description = 'Associate with a group, which is create if needed or simply located otherwise'
112
+ c.example 'Associate with group', 'produce associate-group -a com.example.app group.example.com'
113
+
114
+ c.action do |args, options|
115
+ Produce.config = FastlaneCore::Configuration.create(Produce::Options.available_options, options.__hash__)
116
+
117
+ require 'produce/group'
118
+ Produce::Group.new.associate(options, args)
119
+ end
120
+ end
121
+
38
122
  default_command :create
39
123
 
40
124
  run!
@@ -0,0 +1,95 @@
1
+ require 'spaceship'
2
+ require 'babosa'
3
+
4
+ module Produce
5
+ class Group
6
+ def create(options, args)
7
+ login
8
+
9
+ ENV["CREATED_NEW_GROUP_ID"] = Time.now.to_i.to_s
10
+
11
+ group_identifier = options.group_identifier || ask("Group identifier: ")
12
+
13
+ if app_group_exists? group_identifier
14
+ Helper.log.info "[DevCenter] Group '#{options.group_name} (#{options.group_identifier})' already exists, nothing to do on the Dev Center".green
15
+ ENV["CREATED_NEW_GROUP_ID"] = nil
16
+ # Nothing to do here
17
+ else
18
+ unless options.group_name
19
+ group_name = group_identifier.split(".").map(&:capitalize).reverse.join(' ')
20
+ group_name = valid_name_for(group_name)
21
+ else
22
+ group_name = valid_name_for(options.group_name)
23
+ end
24
+
25
+ Helper.log.info "Creating new app group '#{group_name}' with identifier '#{group_identifier}' on the Apple Dev Center".green
26
+
27
+ group = Spaceship.app_group.create!(group_id: group_identifier,
28
+ name: group_name)
29
+
30
+ Helper.log.info "Created group #{group.app_group_id}"
31
+
32
+ raise "Something went wrong when creating the new app group - it's not listed in the app groups list" unless app_group_exists? group_identifier
33
+
34
+ ENV["CREATED_NEW_GROUP_ID"] = Time.now.to_i.to_s
35
+
36
+ Helper.log.info "Finished creating new app group '#{group_name}' on the Dev Center".green
37
+ end
38
+
39
+ return true
40
+ end
41
+
42
+ def associate(options, args)
43
+ login
44
+
45
+ if !app_exists?
46
+ Helper.log.info "[DevCenter] App '#{Produce.config[:app_identifier]}' does not exist, nothing to associate with the groups".red
47
+ else
48
+ app = Spaceship.app.find(app_identifier)
49
+ raise "Something went wrong when fetching the app - it's not listed in the apps list" unless app != nil
50
+
51
+ new_groups = Array.new
52
+
53
+ Helper.log.info "Validating groups before association"
54
+
55
+ for group_identifier in args
56
+ if !app_group_exists? group_identifier
57
+ Helper.log.info "[DevCenter] App group '#{group_identifier}' does not exist, please create it first, skipping for now".red
58
+ else
59
+ new_groups.push(Spaceship.app_group.find(group_identifier))
60
+ end
61
+ end
62
+
63
+ Helper.log.info "Finalising association with #{new_groups.count} groups"
64
+ app.associate_groups(new_groups)
65
+ Helper.log.info "Done!".green
66
+ end
67
+
68
+ return true
69
+ end
70
+
71
+ def login
72
+ Helper.log.info "Starting login"
73
+ Spaceship.login(Produce.config[:username], nil)
74
+ Spaceship.select_team
75
+ Helper.log.info "Successfully logged in"
76
+ end
77
+
78
+ def app_identifier
79
+ Produce.config[:app_identifier].to_s
80
+ end
81
+
82
+ def app_group_exists? (identifier)
83
+ Spaceship.app_group.find(identifier) != nil
84
+ end
85
+
86
+ def app_exists?
87
+ Spaceship.app.find(app_identifier) != nil
88
+ end
89
+
90
+ def valid_name_for(input)
91
+ latinazed = input.to_slug.transliterate.to_s # remove accents
92
+ latinazed.gsub(/[^0-9A-Za-z\d\s]/, '') # remove non-valid characters
93
+ end
94
+ end
95
+ end
@@ -39,7 +39,7 @@ module Produce
39
39
  description: "Primary Language (e.g. 'English', 'German')",
40
40
  default_value: "English",
41
41
  verify_block: Proc.new do |language|
42
-
42
+
43
43
  end),
44
44
  FastlaneCore::ConfigItem.new(key: :company_name,
45
45
  short_option: "-c",
@@ -47,7 +47,7 @@ module Produce
47
47
  description: "The name of your comapny. Only required if it's the first app you create",
48
48
  optional: true,
49
49
  verify_block: Proc.new do |language|
50
-
50
+
51
51
  end),
52
52
  FastlaneCore::ConfigItem.new(key: :skip_itc,
53
53
  short_option: "-i",
@@ -78,8 +78,7 @@ module Produce
78
78
  default_value: CredentialsManager::AppfileConfig.try_fetch_value(:team_name),
79
79
  verify_block: Proc.new do |value|
80
80
  ENV["FASTLANE_TEAM_NAME"] = value
81
- end),
82
-
81
+ end)
83
82
  ]
84
83
  end
85
84
  end
@@ -0,0 +1,186 @@
1
+ module Produce
2
+ class Service
3
+ def self.enable(options, args)
4
+ self.new.enable(options, args)
5
+ end
6
+
7
+ def self.disable(options, args)
8
+ self.new.disable(options, args)
9
+ end
10
+
11
+ def enable(options, args)
12
+ unless app
13
+ Helper.log.info "[DevCenter] App '#{Produce.config[:app_identifier]}' does not exist".red
14
+ return
15
+ end
16
+
17
+ Helper.log.info "[DevCenter] App found '#{app.name}'".green
18
+ Helper.log.info "Enabling services"
19
+ enabled = update(true, app, options)
20
+ Helper.log.info "Done! Enabled #{enabled} services.".green
21
+ end
22
+
23
+ def disable(options, args)
24
+ unless app
25
+ Helper.log.info "[DevCenter] App '#{Produce.config[:app_identifier]}' does not exist".red
26
+ return
27
+ end
28
+
29
+ Helper.log.info "[DevCenter] App found '#{app.name}'".green
30
+ Helper.log.info "Disabling services"
31
+ disabled = update(false, app, options)
32
+ Helper.log.info "Done! Disabled #{disabled} services.".green
33
+ end
34
+
35
+ def valid_services_for(options)
36
+ allowed_keys = [:app_group, :associated_domains, :data_protection, :healthkit, :homekit,
37
+ :wireless_conf, :icloud, :inter_app_audio, :passbook, :push_notification, :vpn_conf]
38
+ options.__hash__.select { |key, value| allowed_keys.include? key }
39
+ end
40
+
41
+ def update(on, app, options)
42
+ updated = valid_services_for(options).count
43
+
44
+ if options.app_group
45
+ Helper.log.info "\tApp Groups"
46
+
47
+ if on
48
+ app.update_service(Spaceship.app_service.app_group.on)
49
+ else
50
+ app.update_service(Spaceship.app_service.app_group.off)
51
+ end
52
+ end
53
+
54
+ if options.associated_domains
55
+ Helper.log.info "\tAssociated Domains"
56
+
57
+ if on
58
+ app.update_service(Spaceship.app_service.associated_domains.on)
59
+ else
60
+ app.update_service(Spaceship.app_service.associated_domains.off)
61
+ end
62
+ end
63
+
64
+ if options.data_protection
65
+ Helper.log.info "\tData Protection"
66
+
67
+ if on
68
+ case options.data_protection
69
+ when "complete"
70
+ app.update_service(Spaceship.app_service.data_protection.complete)
71
+ when "unlessopen"
72
+ app.update_service(Spaceship.app_service.data_proection.unless_open)
73
+ when "untilfirstauth"
74
+ app.update_service(Spaceship.app_service.data_protection.until_first_auth)
75
+ else
76
+ raise "Unknown service '#{options.data_protection}'. Valid values: 'complete', 'unlessopen', 'untilfirstauth'".red
77
+ end
78
+ else
79
+ app.update_service(Spaceship.app_service.data_protection.off)
80
+ end
81
+ end
82
+
83
+ if options.healthkit
84
+ Helper.log.info "\tHealthKit"
85
+
86
+ if on
87
+ app.update_service(Spaceship.app_service.health_kit.on)
88
+ else
89
+ app.update_service(Spaceship.app_service.health_kit.off)
90
+ end
91
+ end
92
+
93
+ if options.homekit
94
+ Helper.log.info "\tHomeKit"
95
+
96
+ if on
97
+ app.update_service(Spaceship.app_service.home_kit.on)
98
+ else
99
+ app.update_service(Spaceship.app_service.home_kit.off)
100
+ end
101
+ end
102
+
103
+ if options.wireless_conf
104
+ Helper.log.info "\tWireless Accessory Configuration"
105
+
106
+ if on
107
+ app.update_service(Spaceship.app_service.wireless_accessory.on)
108
+ else
109
+ app.update_service(Spaceship.app_service.wireless_accessory.off)
110
+ end
111
+ end
112
+
113
+ if options.icloud
114
+ Helper.log.info "\tiCloud"
115
+
116
+ if on
117
+ case options.icloud
118
+ when "legacy"
119
+ app.update_service(Spaceship.app_service.icloud.on)
120
+ app.update_service(Spaceship.app_service.cloud_kit.xcode5_compatible)
121
+ when "cloudkit"
122
+ app.update_service(Spaceship.app_service.icloud.on)
123
+ app.update_service(Spaceship.app_service.cloud_kit.cloud_kit)
124
+ else
125
+ raise "Unknown service '#{options.icloud}'. Valid values: 'legacy', 'cloudkit'".red
126
+ end
127
+ else
128
+ app.update_service(Spaceship.app_service.icloud.off)
129
+ end
130
+ end
131
+
132
+ if options.inter_app_audio
133
+ Helper.log.info "\tInter-App Audio"
134
+
135
+ if on
136
+ app.update_service(Spaceship.app_service.inter_app_audio.on)
137
+ else
138
+ app.update_service(Spaceship.app_service.inter_app_audio.off)
139
+ end
140
+ end
141
+
142
+ if options.passbook
143
+ Helper.log.info "\tPassbook"
144
+
145
+ if on
146
+ app.update_service(Spaceship.app_service.passbook.on)
147
+ else
148
+ app.update_service(Spaceship.app_service.passbook.off)
149
+ end
150
+ end
151
+
152
+ if options.push_notification
153
+ Helper.log.info "\tPush Notifications"
154
+
155
+ if on
156
+ app.update_service(Spaceship.app_service.push_notification.on)
157
+ else
158
+ app.update_service(Spaceship.app_service.push_notification.off)
159
+ end
160
+ end
161
+
162
+ if options.vpn_conf
163
+ Helper.log.info "\tVPN Configuration"
164
+
165
+ if on
166
+ app.update_service(Spaceship.app_service.vpn_configuration.on)
167
+ else
168
+ app.update_service(Spaceship.app_service.vpn_configuration.off)
169
+ end
170
+ end
171
+
172
+ updated
173
+ end
174
+
175
+ def app
176
+ return @app if @app
177
+
178
+ Helper.log.info "Starting login"
179
+ Spaceship.login(Produce.config[:username], nil)
180
+ Spaceship.select_team
181
+ Helper.log.info "Successfully logged in"
182
+
183
+ @app ||= Spaceship.app.find(Produce.config[:app_identifier].to_s)
184
+ end
185
+ end
186
+ end
@@ -1,3 +1,3 @@
1
1
  module Produce
2
- VERSION = "0.5.1"
2
+ VERSION = "0.6.0"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: produce
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.5.1
4
+ version: 0.6.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Felix Krause
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-07-31 00:00:00.000000000 Z
11
+ date: 2015-08-11 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: fastlane_core
@@ -30,14 +30,14 @@ dependencies:
30
30
  requirements:
31
31
  - - ">="
32
32
  - !ruby/object:Gem::Version
33
- version: 0.3.4
33
+ version: 0.4.0
34
34
  type: :runtime
35
35
  prerelease: false
36
36
  version_requirements: !ruby/object:Gem::Requirement
37
37
  requirements:
38
38
  - - ">="
39
39
  - !ruby/object:Gem::Version
40
- version: 0.3.4
40
+ version: 0.4.0
41
41
  - !ruby/object:Gem::Dependency
42
42
  name: bundler
43
43
  requirement: !ruby/object:Gem::Requirement
@@ -152,9 +152,11 @@ files:
152
152
  - lib/produce/available_default_languages.rb
153
153
  - lib/produce/dependency_checker.rb
154
154
  - lib/produce/developer_center.rb
155
+ - lib/produce/group.rb
155
156
  - lib/produce/itunes_connect.rb
156
157
  - lib/produce/manager.rb
157
158
  - lib/produce/options.rb
159
+ - lib/produce/service.rb
158
160
  - lib/produce/version.rb
159
161
  homepage: https://fastlane.tools
160
162
  licenses: