fwtoolkit 2.1.10 → 2.2.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
  SHA256:
3
- metadata.gz: 1412f688fa4880f18401de37990b97669d0c9eeebb6ccbacfa7f35af57224102
4
- data.tar.gz: 548dccddc4b7992443ef4f53fa126796ac9ff7f4e4af88211ba9c8132003ad53
3
+ metadata.gz: da905252846b93594abad039a5b2dd7b664a66c1c888b18d85c86c76d4bf469a
4
+ data.tar.gz: 12aea9ac3242bd45b9cb25359462284866cc985e3d8f686fa7bd9020599fb2c3
5
5
  SHA512:
6
- metadata.gz: a4dc3b9cdd8d287f49776aaf59b9461b2375d9ef11219b8ad33db6c36efb6ffa3645786336cec789d0760169c3152a88f95afbbdea14d040d74bc6d64641d074
7
- data.tar.gz: f5430084c3142853e23c9aef816de9c52f24fe2740277a4b0767e7d3292d160303921f04e61f753504d4a422b74e2cf7059086ffe190424458897d4a5402020f
6
+ metadata.gz: e69f316fc597998d6321efe5214f3b0cdbbea46eb3ffdf1615c20c3d8d64c7bdab2845d219b6637c7c40500c252142b2752dcbf5aa9a7ed2cbfcf6fdafa5518f
7
+ data.tar.gz: de6564e085a9149664eed2467158860348fc38be59c6824d61fb1da5ae5678ebee0a8446d74cc9db17e3dad6d932248ef918e6d6a0667fe40996fcefaf9584e8
data/lib/fwtoolkit/cli.rb CHANGED
@@ -8,6 +8,7 @@ require 'fwtoolkit/cli/fw_actions'
8
8
  require 'fwtoolkit/cli/xcode'
9
9
  require 'fwtoolkit/cli/project'
10
10
  require 'fwtoolkit/cli/git'
11
+ require 'fwtoolkit/cli/bitrise'
11
12
 
12
13
  module FWToolkit
13
14
  class CLI < Thor
@@ -21,6 +22,7 @@ module FWToolkit
21
22
  puts "FWToolkit version #{FWToolkit::VERSION}"
22
23
  end
23
24
 
25
+ register FWToolkit::Bitrise, 'bitrise', 'bitrise SUBCOMMAND ...ARG', 'Create bitrise configuration files'
24
26
  register FWToolkit::Project, 'proj', 'proj SUBCOMMAND ...ARG', 'Create projects and manage settings'
25
27
  end
26
28
  end
@@ -0,0 +1,40 @@
1
+ require 'thor'
2
+ require 'fileutils'
3
+ require 'fwtoolkit/config'
4
+ require 'fwtoolkit/projectfile'
5
+ require 'fwtoolkit/cli/fw_actions'
6
+ require 'fwtoolkit/cli/thorutils'
7
+
8
+ module FWToolkit
9
+ class Bitrise < Thor
10
+ include Thor::Actions
11
+ include FWToolkit::ThorUtils
12
+
13
+ source_root_templates!
14
+
15
+ desc 'genereate [PROJECT NAME] [CLASS PREFIX]', "Create a new bitrise.yml file for the project, based on a blank file"
16
+ def generate(project_name, class_prefix)
17
+ destination_root = Dir.pwd
18
+
19
+ say "Creating bitrise.yml file in: #{File.expand_path destination_root}/bitrise.yml"
20
+
21
+ invoke FWToolkit::Bitrise, 'new', [destination_root, project_name, class_prefix.upcase]
22
+ end
23
+
24
+ desc 'new', 'Creates a new bitrise YML configuration file'
25
+ def new(project_root, project_name, class_prefix)
26
+ destination_root = project_root
27
+ bitrise_file = File.join(project_root, 'bitrise.yml')
28
+
29
+ Projectfile.load_with_config! :project_name => project_name, :class_prefix => class_prefix.upcase
30
+
31
+ template_config = { :target_platform => Config.target_platform,
32
+ :organization_name => Config.organization_name,
33
+ :project_creator => Config.developer_name }
34
+ template_config.merge! Projectfile.config
35
+
36
+ template_directory "templates/bitrise", destination_root, template_config
37
+ end
38
+
39
+ end
40
+ end
@@ -2,6 +2,7 @@ require 'thor'
2
2
  require 'fwtoolkit/cli/xcode'
3
3
  require 'fwtoolkit/cli/cocoapods'
4
4
  require 'fwtoolkit/cli/git'
5
+ require 'fwtoolkit/cli/bitrise'
5
6
  require 'fwtoolkit/projectfile'
6
7
  require 'fwtoolkit/git_client'
7
8
  require 'fwtoolkit/cli/thorutils'
@@ -25,6 +26,8 @@ module FWToolkit
25
26
 
26
27
  invoke :conf_rvm, [project_language, destination_root]
27
28
 
29
+ invoke FWToolkit::Bitrise, 'new', [destination_root, project_name, class_prefix.upcase]
30
+
28
31
  invoke FWToolkit::Xcode, 'new', [project_language, project_name, class_prefix.upcase, File.join(Dir.pwd, project_name)]
29
32
  invoke FWToolkit::Cocoapods, 'install', [destination_root]
30
33
 
@@ -16,8 +16,8 @@ module FWToolkit
16
16
  end
17
17
 
18
18
  default_config = { :organization_name => 'Future Workshops',
19
- :ruby_version => '1.9.3',
20
- :target_platform => '6.0',
19
+ :ruby_version => '2.5.1',
20
+ :target_platform => '12.1',
21
21
  :ci_server_url => 'http://ci.office.futureworkshops.com',
22
22
  :artifacts_tmp_dir => '/tmp/fwtoolkit/artifacts' }
23
23
 
@@ -1,3 +1,3 @@
1
1
  module FWToolkit
2
- VERSION = "2.1.10"
2
+ VERSION = "2.2.0"
3
3
  end
@@ -0,0 +1,327 @@
1
+ ---
2
+ format_version: 4
3
+ default_step_lib_source: https://github.com/bitrise-io/bitrise-steplib.git
4
+ trigger_map:
5
+ - push_branch: dev
6
+ workflow: internal
7
+ - push_branch: release/next
8
+ workflow: test_external
9
+ - push_branch: master
10
+ workflow: external
11
+ - pull_request_source_branch: "*"
12
+ workflow: test
13
+ workflows:
14
+ test:
15
+ steps:
16
+ - build-number-adjust:
17
+ inputs:
18
+ - change: ''
19
+ - increase: "$FW_BUILD_NUMBER_OFFSET"
20
+ - decrease: ''
21
+ - activate-ssh-key:
22
+ run_if: '{{getenv "SSH_RSA_PRIVATE_KEY" | ne ""}}'
23
+ - script:
24
+ title: Set GEM_HOME env var
25
+ inputs:
26
+ - content: |-
27
+ #!/bin/bash
28
+ set -ev
29
+ envman add --key GEM_HOME --value "$(gem environment gemdir)"
30
+ - git-clone: {}
31
+ - recreate-user-schemes:
32
+ inputs:
33
+ - project_path: "$BITRISE_PROJECT_PATH"
34
+ - cocoapods-install: {}
35
+ - xcode-test:
36
+ inputs:
37
+ - generate_code_coverage_files: 'yes'
38
+ - git::https://github.com/FutureWorkshops/steps-github-status.git@master:
39
+ title: Git Hub status
40
+ run_if: .IsCI
41
+ inputs:
42
+ - auth_token: "$FW_GITHUB_STATUS_AUTH_TOKEN"
43
+ - commit_hash: "$GIT_CLONE_COMMIT_HASH"
44
+ - deploy-to-bitrise-io:
45
+ inputs:
46
+ - notify_email_list: ''
47
+ _add_iconoverlay:
48
+ steps:
49
+ - git::https://github.com/FutureWorkshops/bitrise-step-icon-overlay.git@master:
50
+ title: Git Commit Icon Overlay
51
+ inputs:
52
+ - iconsbundle_name: AppIcon.appiconset
53
+ - overlay_text: "$GIT_CLONE_COMMIT_HASH"
54
+ internal:
55
+ envs:
56
+ - FW_ENVIRONMENT: STAGING
57
+ opts:
58
+ is_expand: true
59
+ - EXPORT_TYPE: enterprise
60
+ opts:
61
+ is_expand: true
62
+ - CODESIGN_IDENTITY: 'iPhone Distribution: Future Workshops Limited'
63
+ opts:
64
+ is_expand: true
65
+ - KEYCHAIN_NAME: fw_enterprise.p12
66
+ opts:
67
+ is_expand: true
68
+ - PRODUCT_BUNDLE_IDENTIFIER: com.futureworkshops.<%= config[:project_name] %>
69
+ opts:
70
+ is_expand: true
71
+ - PROVISIONING_PROFILE_NAME: <%= config[:project_name] %> Internal
72
+ opts:
73
+ is_expand: true
74
+ - DEVPORTAL_TEAM: BQHMJ2C6RL
75
+ opts:
76
+ is_expand: true
77
+ - BITRISE_SCHEME: <%= config[:project_name] %>
78
+ - SWIFT_FLAGS: '"-DSTAGING"'
79
+ after_run:
80
+ - _preflight
81
+ - _add_iconoverlay
82
+ - _build
83
+ test_external:
84
+ envs:
85
+ - FW_ENVIRONMENT: STAGING
86
+ opts:
87
+ is_expand: true
88
+ - EXPORT_TYPE: app-store
89
+ opts:
90
+ is_expand: true
91
+ - CODESIGN_IDENTITY: 'iPhone Distribution: Future Workshops Ltd (F94732585Z)'
92
+ opts:
93
+ is_expand: true
94
+ - KEYCHAIN_NAME: fw_ltd.p12
95
+ opts:
96
+ is_expand: true
97
+ - PRODUCT_BUNDLE_IDENTIFIER: com.futureworkshops.<%= config[:project_name] %>.external
98
+ opts:
99
+ is_expand: true
100
+ - PROVISIONING_PROFILE_NAME: <%= config[:project_name] %> External
101
+ opts:
102
+ is_expand: true
103
+ - PROVISIONING_PROFILE_TYPE: app-store
104
+ opts:
105
+ is_expand: true
106
+ - ITUNESCONNECT_APPID:
107
+ opts:
108
+ is_expand: true
109
+ - DEVPORTAL_TEAM: F94732585Z
110
+ opts:
111
+ is_expand: true
112
+ - ITUNES_TEAM_ID: '462819'
113
+ - BITRISE_SCHEME: <%= config[:project_name] %>
114
+ - SWIFT_FLAGS: '"-DSTAGING"'
115
+ after_run:
116
+ - _preflight
117
+ - _build
118
+ - _deploy_itunes
119
+ external:
120
+ envs:
121
+ - FW_ENVIRONMENT: PRODUCTION
122
+ opts:
123
+ is_expand: true
124
+ - EXPORT_TYPE: app-store
125
+ opts:
126
+ is_expand: true
127
+ - CODESIGN_IDENTITY: 'iPhone Distribution: Future Workshops Ltd (F94732585Z)'
128
+ opts:
129
+ is_expand: true
130
+ - KEYCHAIN_NAME: fw_ltd.p12
131
+ opts:
132
+ is_expand: true
133
+ - PRODUCT_BUNDLE_IDENTIFIER: com.futureworkshops.<%= config[:project_name] %>.external
134
+ opts:
135
+ is_expand: true
136
+ - PROVISIONING_PROFILE_NAME: <%= config[:project_name] %> External
137
+ opts:
138
+ is_expand: true
139
+ - PROVISIONING_PROFILE_TYPE: app-store
140
+ opts:
141
+ is_expand: true
142
+ - ITUNESCONNECT_APPID: ''
143
+ opts:
144
+ is_expand: true
145
+ - DEVPORTAL_TEAM: F94732585Z
146
+ opts:
147
+ is_expand: true
148
+ - FW_BUILD_NUMBER_OFFSET: '0'
149
+ - ITUNES_TEAM_ID: '462819'
150
+ - BITRISE_SCHEME: <%= config[:project_name] %>
151
+ - SWIFT_FLAGS: '"-DPRODUCTION"'
152
+ after_run:
153
+ - _preflight
154
+ - _build
155
+ - _deploy_itunes
156
+ _preflight:
157
+ steps:
158
+ - script:
159
+ title: Set GEM_HOME env var
160
+ inputs:
161
+ - content: |-
162
+ #!/bin/bash
163
+ set -ev
164
+ envman add --key GEM_HOME --value "$(gem environment gemdir)"
165
+ - build-number-adjust:
166
+ inputs:
167
+ - change: ''
168
+ - increase: "$FW_BUILD_NUMBER_OFFSET"
169
+ - decrease: ''
170
+ - activate-ssh-key:
171
+ run_if: '{{getenv "SSH_RSA_PRIVATE_KEY" | ne ""}}'
172
+ - git-clone: {}
173
+ - git-tag:
174
+ run_if: .IsCI
175
+ inputs:
176
+ - tag: ci/$PROJECT_NAME/$BITRISE_TRIGGERED_WORKFLOW_ID/$BITRISE_GIT_BRANCH-$BITRISE_BUILD_NUMBER
177
+ - tag_message: ''
178
+ - recreate-user-schemes:
179
+ inputs:
180
+ - project_path: "$BITRISE_PROJECT_PATH"
181
+ - install-bundler@1.0.0: {}
182
+ _build:
183
+ steps:
184
+ - git::https://github.com/FutureWorkshops/bitrise-step-extract-xcode-settings@master:
185
+ title: Extract Info.plist path
186
+ inputs:
187
+ - xcode_project_path: "$FW_PROJECT_DIR/$FW_XCODEPROJ_NAME"
188
+ - target: "$BITRISE_SCHEME"
189
+ - configuration: Release
190
+ - xcode_setting_key: INFOPLIST_FILE
191
+ - target_variable: INFO_PLIST_PATH
192
+ - set-xcode-build-number:
193
+ inputs:
194
+ - plist_path: "$FW_PROJECT_DIR/$INFO_PLIST_PATH"
195
+ - build_version_offset: ''
196
+ - build_short_version_string: "$VERSION_NUMBER"
197
+ - git::https://github.com/FutureWorkshops/bitrise-step-download-provisioning-profile@master:
198
+ title: Download provisioning profile
199
+ run_if: .IsCI
200
+ inputs:
201
+ - profile_name: "$PROVISIONING_PROFILE_NAME"
202
+ - bundle_id: "$PRODUCT_BUNDLE_IDENTIFIER"
203
+ - team_id: "$DEVPORTAL_TEAM"
204
+ - portal_username: "$DEVPORTAL_USERNAME"
205
+ - portal_password: "$DEVPORTAL_PASSWORD"
206
+ - target_variable: BITRISE_PROVISION_URL
207
+ - target_filename: profile.mobileprovision
208
+ - git::https://github.com/FutureWorkshops/bitrise-step-s3-download.git@master:
209
+ title: Download keychain
210
+ run_if: .IsCI
211
+ inputs:
212
+ - aws_access_key: "$AWS_ACCESS_KEY_ID"
213
+ - aws_secret_access_key: "$AWS_SECRET_ACCESS_KEY"
214
+ - s3_bucket: fw.ci.certificates
215
+ - s3_filepath: "$KEYCHAIN_NAME"
216
+ - certificate-and-profile-installer:
217
+ run_if: .IsCI
218
+ inputs:
219
+ - certificate_url: file://./$KEYCHAIN_NAME
220
+ - provisioning_profile_url: "$BITRISE_PROVISION_URL"
221
+ - git::https://github.com/FutureWorkshops/bitrise-step-change-xcode-settings@master:
222
+ title: Change Bundle ID
223
+ inputs:
224
+ - xcode_project_path: "$FW_PROJECT_DIR/$FW_XCODEPROJ_NAME"
225
+ - target: "$BITRISE_SCHEME"
226
+ - configuration: Release
227
+ - xcode_setting_keys: PRODUCT_BUNDLE_IDENTIFIER
228
+ - new_values: "$PRODUCT_BUNDLE_IDENTIFIER"
229
+ - git::https://github.com/FutureWorkshops/bitrise-step-change-xcode-settings@master:
230
+ title: Set Provisioning Profile and team ID
231
+ inputs:
232
+ - xcode_project_path: "$FW_PROJECT_DIR/$FW_XCODEPROJ_NAME"
233
+ - target: "$BITRISE_SCHEME"
234
+ - configuration: Release
235
+ - xcode_setting_keys: PROVISIONING_PROFILE_SPECIFIER | DEVELOPMENT_TEAM
236
+ - new_values: "$PROVISIONING_PROFILE_NAME | $DEVPORTAL_TEAM"
237
+ - cocoapods-install: {}
238
+ - script:
239
+ title: Set environment
240
+ inputs:
241
+ - content: |-
242
+ #!/bin/bash
243
+ # fail if any commands fails
244
+ set -e
245
+ # debug log
246
+ set -x
247
+ xconfig="$BITRISE_SOURCE_DIR/$FW_PROJECT_DIR/$PROJECT_NAME/Supporting Files/fw-shared.xcconfig"
248
+
249
+ echo "Updating xcconfig file $xconfig"
250
+ echo "" >> "$xconfig"
251
+ echo "OTHER_SWIFT_FLAGS = $SWIFT_FLAGS" >> "$xconfig"
252
+ echo "" >> "$xconfig"
253
+ echo "GCC_PREPROCESSOR_DEFINITIONS = \"CI_BUILD $FW_ENVIRONMENT\"" >> "$xconfig"
254
+ echo "" >> "$xconfig"
255
+
256
+ echo "Final file"
257
+ pbcopy < "$xconfig"
258
+ pbpaste
259
+ - xcode-archive:
260
+ inputs:
261
+ - upload_bitcode: 'no'
262
+ - compile_bitcode: 'no'
263
+ - team_id: "$DEVPORTAL_TEAM"
264
+ - configuration: Release
265
+ - output_dir: "$BITRISE_DEPLOY_DIR/$PROJECT_NAME"
266
+ - force_team_id: ''
267
+ - force_code_sign_identity: "$CODESIGN_IDENTITY"
268
+ - force_provisioning_profile_specifier: ''
269
+ - force_provisioning_profile: ''
270
+ - is_clean_build: 'yes'
271
+ - artifact_name: "$COMPANY_NAME-$PROJECT_NAME-$BITRISE_BUILD_NUMBER"
272
+ - export_method: "$EXPORT_TYPE"
273
+ - custom_export_options_plist_content: "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n<!DOCTYPE
274
+ plist PUBLIC \"-//Apple//DTD PLIST 1.0//EN\" \"http://www.apple.com/DTDs/PropertyList-1.0.dtd\">\n<plist
275
+ version=\"1.0\">\n<dict>\n\t<key>method</key>\n\t<string>$EXPORT_TYPE</string>\n\t<key>teamID</key>\n\t<string>$DEVPORTAL_TEAM</string>\n\t<key>thinning</key>\n\t<string>&lt;none&gt;</string>\n\t<key>provisioningProfiles</key>\n\t<dict>\n\t\t<key>$PRODUCT_BUNDLE_IDENTIFIER</key>\n\t\t<string>$PROVISIONING_PROFILE_NAME</string>\n\t</dict>\n</dict>\n</plist>"
276
+ - git::https://github.com/FutureWorkshops/steps-github-status.git@master:
277
+ title: Git Hub status
278
+ run_if: .IsCI
279
+ inputs:
280
+ - auth_token: "$FW_GITHUB_STATUS_AUTH_TOKEN"
281
+ - commit_hash: "$GIT_CLONE_COMMIT_HASH"
282
+ - deploy-to-bitrise-io:
283
+ title: Deploy to Bitrise.io - IPA
284
+ inputs:
285
+ - is_enable_public_page: 'false'
286
+ - deploy-to-bitrise-io:
287
+ title: Deploy to Bitrise.io - IPA
288
+ inputs:
289
+ - deploy_path: "$BITRISE_DEPLOY_DIR/$PROJECT_NAME"
290
+ - is_enable_public_page: 'false'
291
+ _deploy_itunes:
292
+ steps:
293
+ - deploy-to-itunesconnect-deliver:
294
+ run_if: .IsCI
295
+ inputs:
296
+ - itunescon_user: "$ITUNESCONNECT_USERNAME"
297
+ - password: "$ITUNESCONNECT_PASSWORD"
298
+ - app_id: "$ITUNESCONNECT_APPID"
299
+ - team_id: "$ITUNES_TEAM_ID"
300
+ - options: ''
301
+ app:
302
+ envs:
303
+ - opts:
304
+ is_expand: false
305
+ BITRISE_PROJECT_PATH: <%= config[:project_name] %>.xcworkspace
306
+ - opts:
307
+ is_expand: false
308
+ BITRISE_SCHEME: <%= config[:project_name] %>
309
+ - opts:
310
+ is_expand: false
311
+ FW_PROJECT_DIR: <%= config[:project_name] %>
312
+ - opts:
313
+ is_expand: true
314
+ FW_XCODEPROJ_NAME: <%= config[:project_name] %>.xcodeproj
315
+ - opts:
316
+ is_expand: true
317
+ DEVPORTAL_USERNAME: c-i@futureworkshops.com
318
+ - opts:
319
+ is_expand: true
320
+ FW_BUILD_NUMBER_OFFSET: '0'
321
+ - COMPANY_NAME: <%= config[:class_prefix] %>
322
+ opts:
323
+ is_expand: true
324
+ - PROJECT_NAME: <%= config[:project_name] %>
325
+ opts:
326
+ is_expand: true
327
+ - VERSION_NUMBER: 1.0.0
@@ -0,0 +1,327 @@
1
+ ---
2
+ format_version: 4
3
+ default_step_lib_source: https://github.com/bitrise-io/bitrise-steplib.git
4
+ trigger_map:
5
+ - push_branch: dev
6
+ workflow: internal
7
+ - push_branch: release/next
8
+ workflow: test_external
9
+ - push_branch: master
10
+ workflow: external
11
+ - pull_request_source_branch: "*"
12
+ workflow: test
13
+ workflows:
14
+ test:
15
+ steps:
16
+ - build-number-adjust:
17
+ inputs:
18
+ - change: ''
19
+ - increase: "$FW_BUILD_NUMBER_OFFSET"
20
+ - decrease: ''
21
+ - activate-ssh-key:
22
+ run_if: '{{getenv "SSH_RSA_PRIVATE_KEY" | ne ""}}'
23
+ - script:
24
+ title: Set GEM_HOME env var
25
+ inputs:
26
+ - content: |-
27
+ #!/bin/bash
28
+ set -ev
29
+ envman add --key GEM_HOME --value "$(gem environment gemdir)"
30
+ - git-clone: {}
31
+ - recreate-user-schemes:
32
+ inputs:
33
+ - project_path: "$BITRISE_PROJECT_PATH"
34
+ - cocoapods-install: {}
35
+ - xcode-test:
36
+ inputs:
37
+ - generate_code_coverage_files: 'yes'
38
+ - git::https://github.com/FutureWorkshops/steps-github-status.git@master:
39
+ title: Git Hub status
40
+ run_if: .IsCI
41
+ inputs:
42
+ - auth_token: "$FW_GITHUB_STATUS_AUTH_TOKEN"
43
+ - commit_hash: "$GIT_CLONE_COMMIT_HASH"
44
+ - deploy-to-bitrise-io:
45
+ inputs:
46
+ - notify_email_list: ''
47
+ _add_iconoverlay:
48
+ steps:
49
+ - git::https://github.com/FutureWorkshops/bitrise-step-icon-overlay.git@master:
50
+ title: Git Commit Icon Overlay
51
+ inputs:
52
+ - iconsbundle_name: AppIcon.appiconset
53
+ - overlay_text: "$GIT_CLONE_COMMIT_HASH"
54
+ internal:
55
+ envs:
56
+ - FW_ENVIRONMENT: STAGING
57
+ opts:
58
+ is_expand: true
59
+ - EXPORT_TYPE: enterprise
60
+ opts:
61
+ is_expand: true
62
+ - CODESIGN_IDENTITY: 'iPhone Distribution: Future Workshops Limited'
63
+ opts:
64
+ is_expand: true
65
+ - KEYCHAIN_NAME: fw_enterprise.p12
66
+ opts:
67
+ is_expand: true
68
+ - PRODUCT_BUNDLE_IDENTIFIER: com.futureworkshops.<%= config[:project_name] %>
69
+ opts:
70
+ is_expand: true
71
+ - PROVISIONING_PROFILE_NAME: <%= config[:project_name] %> Internal
72
+ opts:
73
+ is_expand: true
74
+ - DEVPORTAL_TEAM: BQHMJ2C6RL
75
+ opts:
76
+ is_expand: true
77
+ - BITRISE_SCHEME: <%= config[:project_name] %>
78
+ - SWIFT_FLAGS: '"-DSTAGING"'
79
+ after_run:
80
+ - _preflight
81
+ - _add_iconoverlay
82
+ - _build
83
+ test_external:
84
+ envs:
85
+ - FW_ENVIRONMENT: STAGING
86
+ opts:
87
+ is_expand: true
88
+ - EXPORT_TYPE: app-store
89
+ opts:
90
+ is_expand: true
91
+ - CODESIGN_IDENTITY: 'iPhone Distribution: Future Workshops Ltd (F94732585Z)'
92
+ opts:
93
+ is_expand: true
94
+ - KEYCHAIN_NAME: fw_ltd.p12
95
+ opts:
96
+ is_expand: true
97
+ - PRODUCT_BUNDLE_IDENTIFIER: com.futureworkshops.<%= config[:project_name] %>.external
98
+ opts:
99
+ is_expand: true
100
+ - PROVISIONING_PROFILE_NAME: <%= config[:project_name] %> External
101
+ opts:
102
+ is_expand: true
103
+ - PROVISIONING_PROFILE_TYPE: app-store
104
+ opts:
105
+ is_expand: true
106
+ - ITUNESCONNECT_APPID:
107
+ opts:
108
+ is_expand: true
109
+ - DEVPORTAL_TEAM: F94732585Z
110
+ opts:
111
+ is_expand: true
112
+ - ITUNES_TEAM_ID: '462819'
113
+ - BITRISE_SCHEME: <%= config[:project_name] %>
114
+ - SWIFT_FLAGS: '"-DSTAGING"'
115
+ after_run:
116
+ - _preflight
117
+ - _build
118
+ - _deploy_itunes
119
+ external:
120
+ envs:
121
+ - FW_ENVIRONMENT: PRODUCTION
122
+ opts:
123
+ is_expand: true
124
+ - EXPORT_TYPE: app-store
125
+ opts:
126
+ is_expand: true
127
+ - CODESIGN_IDENTITY: 'iPhone Distribution: Future Workshops Ltd (F94732585Z)'
128
+ opts:
129
+ is_expand: true
130
+ - KEYCHAIN_NAME: fw_ltd.p12
131
+ opts:
132
+ is_expand: true
133
+ - PRODUCT_BUNDLE_IDENTIFIER: com.futureworkshops.<%= config[:project_name] %>.external
134
+ opts:
135
+ is_expand: true
136
+ - PROVISIONING_PROFILE_NAME: <%= config[:project_name] %> External
137
+ opts:
138
+ is_expand: true
139
+ - PROVISIONING_PROFILE_TYPE: app-store
140
+ opts:
141
+ is_expand: true
142
+ - ITUNESCONNECT_APPID: ''
143
+ opts:
144
+ is_expand: true
145
+ - DEVPORTAL_TEAM: F94732585Z
146
+ opts:
147
+ is_expand: true
148
+ - FW_BUILD_NUMBER_OFFSET: '0'
149
+ - ITUNES_TEAM_ID: '462819'
150
+ - BITRISE_SCHEME: <%= config[:project_name] %>
151
+ - SWIFT_FLAGS: '"-DPRODUCTION"'
152
+ after_run:
153
+ - _preflight
154
+ - _build
155
+ - _deploy_itunes
156
+ _preflight:
157
+ steps:
158
+ - script:
159
+ title: Set GEM_HOME env var
160
+ inputs:
161
+ - content: |-
162
+ #!/bin/bash
163
+ set -ev
164
+ envman add --key GEM_HOME --value "$(gem environment gemdir)"
165
+ - build-number-adjust:
166
+ inputs:
167
+ - change: ''
168
+ - increase: "$FW_BUILD_NUMBER_OFFSET"
169
+ - decrease: ''
170
+ - activate-ssh-key:
171
+ run_if: '{{getenv "SSH_RSA_PRIVATE_KEY" | ne ""}}'
172
+ - git-clone: {}
173
+ - git-tag:
174
+ run_if: .IsCI
175
+ inputs:
176
+ - tag: ci/$PROJECT_NAME/$BITRISE_TRIGGERED_WORKFLOW_ID/$BITRISE_GIT_BRANCH-$BITRISE_BUILD_NUMBER
177
+ - tag_message: ''
178
+ - recreate-user-schemes:
179
+ inputs:
180
+ - project_path: "$BITRISE_PROJECT_PATH"
181
+ - install-bundler@1.0.0: {}
182
+ _build:
183
+ steps:
184
+ - git::https://github.com/FutureWorkshops/bitrise-step-extract-xcode-settings@master:
185
+ title: Extract Info.plist path
186
+ inputs:
187
+ - xcode_project_path: "$FW_PROJECT_DIR/$FW_XCODEPROJ_NAME"
188
+ - target: "$BITRISE_SCHEME"
189
+ - configuration: Release
190
+ - xcode_setting_key: INFOPLIST_FILE
191
+ - target_variable: INFO_PLIST_PATH
192
+ - set-xcode-build-number:
193
+ inputs:
194
+ - plist_path: "$FW_PROJECT_DIR/$INFO_PLIST_PATH"
195
+ - build_version_offset: ''
196
+ - build_short_version_string: "$VERSION_NUMBER"
197
+ - git::https://github.com/FutureWorkshops/bitrise-step-download-provisioning-profile@master:
198
+ title: Download provisioning profile
199
+ run_if: .IsCI
200
+ inputs:
201
+ - profile_name: "$PROVISIONING_PROFILE_NAME"
202
+ - bundle_id: "$PRODUCT_BUNDLE_IDENTIFIER"
203
+ - team_id: "$DEVPORTAL_TEAM"
204
+ - portal_username: "$DEVPORTAL_USERNAME"
205
+ - portal_password: "$DEVPORTAL_PASSWORD"
206
+ - target_variable: BITRISE_PROVISION_URL
207
+ - target_filename: profile.mobileprovision
208
+ - git::https://github.com/FutureWorkshops/bitrise-step-s3-download.git@master:
209
+ title: Download keychain
210
+ run_if: .IsCI
211
+ inputs:
212
+ - aws_access_key: "$AWS_ACCESS_KEY_ID"
213
+ - aws_secret_access_key: "$AWS_SECRET_ACCESS_KEY"
214
+ - s3_bucket: fw.ci.certificates
215
+ - s3_filepath: "$KEYCHAIN_NAME"
216
+ - certificate-and-profile-installer:
217
+ run_if: .IsCI
218
+ inputs:
219
+ - certificate_url: file://./$KEYCHAIN_NAME
220
+ - provisioning_profile_url: "$BITRISE_PROVISION_URL"
221
+ - git::https://github.com/FutureWorkshops/bitrise-step-change-xcode-settings@master:
222
+ title: Change Bundle ID
223
+ inputs:
224
+ - xcode_project_path: "$FW_PROJECT_DIR/$FW_XCODEPROJ_NAME"
225
+ - target: "$BITRISE_SCHEME"
226
+ - configuration: Release
227
+ - xcode_setting_keys: PRODUCT_BUNDLE_IDENTIFIER
228
+ - new_values: "$PRODUCT_BUNDLE_IDENTIFIER"
229
+ - git::https://github.com/FutureWorkshops/bitrise-step-change-xcode-settings@master:
230
+ title: Set Provisioning Profile and team ID
231
+ inputs:
232
+ - xcode_project_path: "$FW_PROJECT_DIR/$FW_XCODEPROJ_NAME"
233
+ - target: "$BITRISE_SCHEME"
234
+ - configuration: Release
235
+ - xcode_setting_keys: PROVISIONING_PROFILE_SPECIFIER | DEVELOPMENT_TEAM
236
+ - new_values: "$PROVISIONING_PROFILE_NAME | $DEVPORTAL_TEAM"
237
+ - cocoapods-install: {}
238
+ - script:
239
+ title: Set environment
240
+ inputs:
241
+ - content: |-
242
+ #!/bin/bash
243
+ # fail if any commands fails
244
+ set -e
245
+ # debug log
246
+ set -x
247
+ xconfig="$BITRISE_SOURCE_DIR/$FW_PROJECT_DIR/$PROJECT_NAME/Supporting Files/fw-shared.xcconfig"
248
+
249
+ echo "Updating xcconfig file $xconfig"
250
+ echo "" >> "$xconfig"
251
+ echo "OTHER_SWIFT_FLAGS = $SWIFT_FLAGS" >> "$xconfig"
252
+ echo "" >> "$xconfig"
253
+ echo "GCC_PREPROCESSOR_DEFINITIONS = \"CI_BUILD $FW_ENVIRONMENT\"" >> "$xconfig"
254
+ echo "" >> "$xconfig"
255
+
256
+ echo "Final file"
257
+ pbcopy < "$xconfig"
258
+ pbpaste
259
+ - xcode-archive:
260
+ inputs:
261
+ - upload_bitcode: 'no'
262
+ - compile_bitcode: 'no'
263
+ - team_id: "$DEVPORTAL_TEAM"
264
+ - configuration: Release
265
+ - output_dir: "$BITRISE_DEPLOY_DIR/$PROJECT_NAME"
266
+ - force_team_id: ''
267
+ - force_code_sign_identity: "$CODESIGN_IDENTITY"
268
+ - force_provisioning_profile_specifier: ''
269
+ - force_provisioning_profile: ''
270
+ - is_clean_build: 'yes'
271
+ - artifact_name: "$COMPANY_NAME-$PROJECT_NAME-$BITRISE_BUILD_NUMBER"
272
+ - export_method: "$EXPORT_TYPE"
273
+ - custom_export_options_plist_content: "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n<!DOCTYPE
274
+ plist PUBLIC \"-//Apple//DTD PLIST 1.0//EN\" \"http://www.apple.com/DTDs/PropertyList-1.0.dtd\">\n<plist
275
+ version=\"1.0\">\n<dict>\n\t<key>method</key>\n\t<string>$EXPORT_TYPE</string>\n\t<key>teamID</key>\n\t<string>$DEVPORTAL_TEAM</string>\n\t<key>thinning</key>\n\t<string>&lt;none&gt;</string>\n\t<key>provisioningProfiles</key>\n\t<dict>\n\t\t<key>$PRODUCT_BUNDLE_IDENTIFIER</key>\n\t\t<string>$PROVISIONING_PROFILE_NAME</string>\n\t</dict>\n</dict>\n</plist>"
276
+ - git::https://github.com/FutureWorkshops/steps-github-status.git@master:
277
+ title: Git Hub status
278
+ run_if: .IsCI
279
+ inputs:
280
+ - auth_token: "$FW_GITHUB_STATUS_AUTH_TOKEN"
281
+ - commit_hash: "$GIT_CLONE_COMMIT_HASH"
282
+ - deploy-to-bitrise-io:
283
+ title: Deploy to Bitrise.io - IPA
284
+ inputs:
285
+ - is_enable_public_page: 'false'
286
+ - deploy-to-bitrise-io:
287
+ title: Deploy to Bitrise.io - IPA
288
+ inputs:
289
+ - deploy_path: "$BITRISE_DEPLOY_DIR/$PROJECT_NAME"
290
+ - is_enable_public_page: 'false'
291
+ _deploy_itunes:
292
+ steps:
293
+ - deploy-to-itunesconnect-deliver:
294
+ run_if: .IsCI
295
+ inputs:
296
+ - itunescon_user: "$ITUNESCONNECT_USERNAME"
297
+ - password: "$ITUNESCONNECT_PASSWORD"
298
+ - app_id: "$ITUNESCONNECT_APPID"
299
+ - team_id: "$ITUNES_TEAM_ID"
300
+ - options: ''
301
+ app:
302
+ envs:
303
+ - opts:
304
+ is_expand: false
305
+ BITRISE_PROJECT_PATH: <%= config[:project_name] %>.xcworkspace
306
+ - opts:
307
+ is_expand: false
308
+ BITRISE_SCHEME: <%= config[:project_name] %>
309
+ - opts:
310
+ is_expand: false
311
+ FW_PROJECT_DIR: <%= config[:project_name] %>
312
+ - opts:
313
+ is_expand: true
314
+ FW_XCODEPROJ_NAME: <%= config[:project_name] %>.xcodeproj
315
+ - opts:
316
+ is_expand: true
317
+ DEVPORTAL_USERNAME: c-i@futureworkshops.com
318
+ - opts:
319
+ is_expand: true
320
+ FW_BUILD_NUMBER_OFFSET: '0'
321
+ - COMPANY_NAME: <%= config[:class_prefix] %>
322
+ opts:
323
+ is_expand: true
324
+ - PROJECT_NAME: <%= config[:project_name] %>
325
+ opts:
326
+ is_expand: true
327
+ - VERSION_NUMBER: 1.0.0
@@ -4,6 +4,13 @@ log/
4
4
  db/production.sqlite3
5
5
  db/development.sqlite3
6
6
 
7
+ # CI
8
+ bitrise.yml
9
+ .bitrise*
10
+
11
+ #CocoaPods
12
+ Pods/CocoaPodsKeys
13
+
7
14
  # Xcode
8
15
  build/*
9
16
  *.pbxuser
@@ -326,6 +326,7 @@
326
326
  ONLY_ACTIVE_ARCH = YES;
327
327
  SDKROOT = iphoneos;
328
328
  SWIFT_OPTIMIZATION_LEVEL = "-Onone";
329
+ SWIFT_VERSION = 4.2;
329
330
  TARGETED_DEVICE_FAMILY = "1,2";
330
331
  };
331
332
  name = Debug;
@@ -371,6 +372,7 @@
371
372
  MTL_ENABLE_DEBUG_INFO = NO;
372
373
  SDKROOT = iphoneos;
373
374
  SWIFT_OPTIMIZATION_LEVEL = "-Owholemodule";
375
+ SWIFT_VERSION = 4.2;
374
376
  TARGETED_DEVICE_FAMILY = "1,2";
375
377
  VALIDATE_PRODUCT = YES;
376
378
  };
@@ -389,7 +391,6 @@
389
391
  PRODUCT_NAME = "$(TARGET_NAME)";
390
392
  PROVISIONING_PROFILE_SPECIFIER = "";
391
393
  SWIFT_SWIFT3_OBJC_INFERENCE = Default;
392
- SWIFT_VERSION = 4.0;
393
394
  };
394
395
  name = Debug;
395
396
  };
@@ -406,7 +407,6 @@
406
407
  PRODUCT_NAME = "$(TARGET_NAME)";
407
408
  PROVISIONING_PROFILE_SPECIFIER = "";
408
409
  SWIFT_SWIFT3_OBJC_INFERENCE = Default;
409
- SWIFT_VERSION = 4.0;
410
410
  };
411
411
  name = Release;
412
412
  };
@@ -419,7 +419,6 @@
419
419
  PRODUCT_BUNDLE_IDENTIFIER = "com.futureworkshops.<%= config[:project_name] %>Tests";
420
420
  PRODUCT_NAME = "$(TARGET_NAME)";
421
421
  SWIFT_SWIFT3_OBJC_INFERENCE = Default;
422
- SWIFT_VERSION = 4.0;
423
422
  TEST_HOST = "$(BUILT_PRODUCTS_DIR)/<%= config[:project_name] %>.app/<%= config[:project_name] %>";
424
423
  };
425
424
  name = Debug;
@@ -433,7 +432,6 @@
433
432
  PRODUCT_BUNDLE_IDENTIFIER = "com.futureworkshops.<%= config[:project_name] %>Tests";
434
433
  PRODUCT_NAME = "$(TARGET_NAME)";
435
434
  SWIFT_SWIFT3_OBJC_INFERENCE = Default;
436
- SWIFT_VERSION = 4.0;
437
435
  TEST_HOST = "$(BUILT_PRODUCTS_DIR)/<%= config[:project_name] %>.app/<%= config[:project_name] %>";
438
436
  };
439
437
  name = Release;
@@ -19,7 +19,7 @@ class AppDelegate: UIResponder, UIApplicationDelegate {
19
19
  var window: UIWindow?
20
20
 
21
21
 
22
- func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplicationLaunchOptionsKey: Any]?) -> Bool {
22
+ func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]?) -> Bool {
23
23
  // Override point for customization after application launch.
24
24
  return true
25
25
  }
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: fwtoolkit
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.1.10
4
+ version: 2.2.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Future Workshops
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2018-05-28 00:00:00.000000000 Z
11
+ date: 2019-02-14 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rspec-rails
@@ -236,6 +236,7 @@ files:
236
236
  - features/xcode/create.feature
237
237
  - lib/fwtoolkit.rb
238
238
  - lib/fwtoolkit/cli.rb
239
+ - lib/fwtoolkit/cli/bitrise.rb
239
240
  - lib/fwtoolkit/cli/cocoapods.rb
240
241
  - lib/fwtoolkit/cli/ext/thor.rb
241
242
  - lib/fwtoolkit/cli/fw_actions.rb
@@ -272,11 +273,12 @@ files:
272
273
  - spec/support/ctx_rake.rb
273
274
  - spec/support/double_helper.rb
274
275
  - spec/support/project_generator.rb
276
+ - templates/bitrise/bitrise.yml.tt
277
+ - templates/default_project/bitrise/bitrise.yml.tt
275
278
  - templates/default_project/git/.github/PULL_REQUEST_TEMPLATE.md
276
279
  - templates/default_project/git/.gitignore
277
280
  - templates/default_project/rvm/Gemfile
278
281
  - templates/objc_project/xcode/%project_name%.xcworkspace/contents.xcworkspacedata.tt
279
- - templates/objc_project/xcode/%project_name%.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist
280
282
  - templates/objc_project/xcode/%project_name%/%project_name%.entitlements
281
283
  - templates/objc_project/xcode/%project_name%/%project_name%.xcodeproj/project.pbxproj.tt
282
284
  - templates/objc_project/xcode/%project_name%/%project_name%.xcodeproj/project.xcworkspace/contents.xcworkspacedata.tt
@@ -314,7 +316,6 @@ files:
314
316
  - templates/objc_project/xcode/%project_name%/%target_name%/Supporting Files/main.m.tt
315
317
  - templates/objc_project/xcode/%project_name%/%target_name%Tests/%class_prefix%%project_name%Tests.m.tt
316
318
  - templates/objc_project/xcode/%project_name%/%target_name%Tests/Resources/Info.plist
317
- - templates/objc_project/xcode/.DS_Store
318
319
  - templates/objc_project/xcode/Podfile.tt
319
320
  - templates/objc_project/xcode/Rakefile.tt
320
321
  - templates/swift_project/xcode/%project_name%.xcworkspace/contents.xcworkspacedata.tt
@@ -375,7 +376,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
375
376
  version: '0'
376
377
  requirements: []
377
378
  rubyforge_project:
378
- rubygems_version: 2.7.6
379
+ rubygems_version: 2.7.7
379
380
  signing_key:
380
381
  specification_version: 4
381
382
  summary: Future Workshops project tools
@@ -1,8 +0,0 @@
1
- <?xml version="1.0" encoding="UTF-8"?>
2
- <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
3
- <plist version="1.0">
4
- <dict>
5
- <key>IDEDidComputeMac32BitWarning</key>
6
- <true/>
7
- </dict>
8
- </plist>
Binary file