fastlane 2.157.3 → 2.161.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 +4 -4
- data/README.md +72 -72
- data/deliver/lib/deliver/options.rb +17 -1
- data/deliver/lib/deliver/runner.rb +36 -5
- data/deliver/lib/deliver/upload_metadata.rb +36 -6
- data/deliver/lib/deliver/upload_price_tier.rb +7 -2
- data/{pilot/lib/pilot/.manager.rb.swp → fastlane/lib/fastlane/.erb_template_helper.rb.swp} +0 -0
- data/fastlane/lib/fastlane/actions/{.ensure_git_status_clean.rb.swp → .git_commit.rb.swp} +0 -0
- data/fastlane/lib/fastlane/actions/actions_helper.rb +20 -1
- data/fastlane/lib/fastlane/actions/app_store_build_number.rb +1 -0
- data/fastlane/lib/fastlane/actions/app_store_connect_api_key.rb +6 -1
- data/fastlane/lib/fastlane/actions/clean_build_artifacts.rb +1 -0
- data/fastlane/lib/fastlane/actions/docs/capture_android_screenshots.md +2 -2
- data/fastlane/lib/fastlane/actions/docs/capture_ios_screenshots.md +1 -1
- data/fastlane/lib/fastlane/actions/docs/create_app_online.md +1 -1
- data/fastlane/lib/fastlane/actions/docs/frame_screenshots.md +3 -2
- data/fastlane/lib/fastlane/actions/docs/run_tests.md +2 -2
- data/fastlane/lib/fastlane/actions/docs/sync_code_signing.md +3 -3
- data/fastlane/lib/fastlane/actions/docs/upload_to_play_store.md +2 -2
- data/fastlane/lib/fastlane/actions/docs/upload_to_testflight.md +2 -2
- data/fastlane/lib/fastlane/actions/download_dsyms.rb +34 -7
- data/fastlane/lib/fastlane/actions/ensure_git_status_clean.rb +13 -2
- data/fastlane/lib/fastlane/actions/set_changelog.rb +2 -0
- data/fastlane/lib/fastlane/helper/git_helper.rb +2 -0
- data/fastlane/lib/fastlane/swift_fastlane_api_generator.rb +6 -4
- data/fastlane/lib/fastlane/swift_fastlane_function.rb +1 -1
- data/fastlane/lib/fastlane/version.rb +1 -1
- data/fastlane/swift/Actions.swift +2 -1
- data/fastlane/swift/Appfile.swift +2 -4
- data/fastlane/swift/ArgumentProcessor.swift +2 -6
- data/fastlane/swift/ControlCommand.swift +2 -5
- data/fastlane/swift/Deliverfile.swift +5 -2
- data/fastlane/swift/DeliverfileProtocol.swift +15 -4
- data/fastlane/swift/Fastfile.swift +5 -1
- data/fastlane/swift/Fastlane.swift +2285 -2240
- data/fastlane/swift/FastlaneSwiftRunner/FastlaneSwiftRunner.xcodeproj/project.pbxproj +5 -5
- data/fastlane/swift/Gymfile.swift +5 -2
- data/fastlane/swift/GymfileProtocol.swift +6 -3
- data/fastlane/swift/LaneFileProtocol.swift +42 -29
- data/fastlane/swift/MainProcess.swift +77 -0
- data/fastlane/swift/Matchfile.swift +5 -2
- data/fastlane/swift/MatchfileProtocol.swift +7 -4
- data/fastlane/swift/Plugins.swift +2 -1
- data/fastlane/swift/Precheckfile.swift +5 -2
- data/fastlane/swift/PrecheckfileProtocol.swift +18 -3
- data/fastlane/swift/RubyCommand.swift +2 -6
- data/fastlane/swift/RubyCommandable.swift +2 -6
- data/fastlane/swift/Runner.swift +5 -9
- data/fastlane/swift/RunnerArgument.swift +2 -6
- data/fastlane/swift/Scanfile.swift +5 -2
- data/fastlane/swift/ScanfileProtocol.swift +6 -3
- data/fastlane/swift/Screengrabfile.swift +5 -2
- data/fastlane/swift/ScreengrabfileProtocol.swift +6 -3
- data/fastlane/swift/Snapshotfile.swift +5 -2
- data/fastlane/swift/SnapshotfileProtocol.swift +6 -3
- data/fastlane/swift/SocketClient.swift +3 -7
- data/fastlane/swift/SocketClientDelegateProtocol.swift +2 -6
- data/fastlane/swift/SocketResponse.swift +2 -6
- data/fastlane/swift/formatting/Brewfile.lock.json +18 -10
- data/fastlane/swift/main.swift +4 -8
- data/fastlane/swift/upgrade_manifest.json +1 -1
- data/frameit/lib/frameit/editor.rb +1 -0
- data/match/lib/match/importer.rb +5 -2
- data/match/lib/match/options.rb +1 -1
- data/match/lib/match/spaceship_ensure.rb +3 -3
- data/pilot/lib/pilot/options.rb +2 -2
- data/precheck/lib/precheck/options.rb +25 -0
- data/precheck/lib/precheck/rule_processor.rb +94 -60
- data/precheck/lib/precheck/runner.rb +26 -5
- data/produce/lib/produce/itunes_connect.rb +2 -0
- data/sigh/lib/sigh/runner.rb +2 -0
- data/snapshot/lib/assets/SnapshotHelper.swift +17 -2
- data/spaceship/README.md +1 -1
- data/spaceship/lib/spaceship/{connect_api/.DS_Store → .DS_Store} +0 -0
- data/spaceship/lib/spaceship/connect_api/client.rb +34 -13
- data/{fastlane/lib/fastlane/actions/.update_project_provisioning.rb.swp → spaceship/lib/spaceship/connect_api/models/.app_store_version_submission.rb.swp} +0 -0
- data/spaceship/lib/spaceship/connect_api/models/app.rb +17 -9
- data/spaceship/lib/spaceship/connect_api/models/app_info.rb +1 -0
- data/spaceship/lib/spaceship/connect_api/models/app_screenshot_set.rb +2 -2
- data/spaceship/lib/spaceship/connect_api/models/app_store_version.rb +3 -5
- data/spaceship/lib/spaceship/connect_api/models/app_store_version_localization.rb +3 -5
- data/spaceship/lib/spaceship/connect_api/models/app_store_version_phased_release.rb +21 -0
- data/spaceship/lib/spaceship/connect_api/spaceship.rb +3 -2
- data/spaceship/lib/spaceship/connect_api/tunes/tunes.rb +29 -9
- data/spaceship/lib/spaceship/helper/net_http_generic_request.rb +11 -5
- metadata +24 -26
- data/fastlane/lib/fastlane/actions/.hockey.rb.swp +0 -0
- data/fastlane/lib/fastlane/actions/.slack.rb.swp +0 -0
- data/fastlane/swift/FastlaneSwiftRunner/FastlaneSwiftRunner.xcodeproj/project.xcworkspace/xcuserdata/josh.xcuserdatad/UserInterfaceState.xcuserstate +0 -0
@@ -9,6 +9,7 @@
|
|
9
9
|
/* Begin PBXBuildFile section */
|
10
10
|
0311E387230AC1B20060BB5C /* Plugins.swift in Sources */ = {isa = PBXBuildFile; fileRef = 0311E386230AC1B20060BB5C /* Plugins.swift */; };
|
11
11
|
0311E38B230AC9490060BB5C /* Actions.swift in Sources */ = {isa = PBXBuildFile; fileRef = 0311E38A230AC9490060BB5C /* Actions.swift */; };
|
12
|
+
1257253924B7992C00E04FA3 /* main.swift in Sources */ = {isa = PBXBuildFile; fileRef = 1257253824B7992B00E04FA3 /* main.swift */; };
|
12
13
|
B302067B1F5E3E9000DE6EBD /* SnapshotfileProtocol.swift in Sources */ = {isa = PBXBuildFile; fileRef = B30206741F5E3E9000DE6EBD /* SnapshotfileProtocol.swift */; };
|
13
14
|
B302067C1F5E3E9000DE6EBD /* GymfileProtocol.swift in Sources */ = {isa = PBXBuildFile; fileRef = B30206751F5E3E9000DE6EBD /* GymfileProtocol.swift */; };
|
14
15
|
B302067D1F5E3E9000DE6EBD /* MatchfileProtocol.swift in Sources */ = {isa = PBXBuildFile; fileRef = B30206761F5E3E9000DE6EBD /* MatchfileProtocol.swift */; };
|
@@ -18,7 +19,6 @@
|
|
18
19
|
B30206811F5E3E9000DE6EBD /* DeliverfileProtocol.swift in Sources */ = {isa = PBXBuildFile; fileRef = B302067A1F5E3E9000DE6EBD /* DeliverfileProtocol.swift */; };
|
19
20
|
B3BA65A61F5A269100B34850 /* Fastlane.swift in Sources */ = {isa = PBXBuildFile; fileRef = B3BA659D1F5A269100B34850 /* Fastlane.swift */; };
|
20
21
|
B3BA65A71F5A269100B34850 /* LaneFileProtocol.swift in Sources */ = {isa = PBXBuildFile; fileRef = B3BA659E1F5A269100B34850 /* LaneFileProtocol.swift */; };
|
21
|
-
B3BA65A81F5A269100B34850 /* main.swift in Sources */ = {isa = PBXBuildFile; fileRef = B3BA659F1F5A269100B34850 /* main.swift */; };
|
22
22
|
B3BA65A91F5A269100B34850 /* RubyCommand.swift in Sources */ = {isa = PBXBuildFile; fileRef = B3BA65A01F5A269100B34850 /* RubyCommand.swift */; };
|
23
23
|
B3BA65AA1F5A269100B34850 /* Runner.swift in Sources */ = {isa = PBXBuildFile; fileRef = B3BA65A11F5A269100B34850 /* Runner.swift */; };
|
24
24
|
B3BA65AB1F5A269100B34850 /* SocketClient.swift in Sources */ = {isa = PBXBuildFile; fileRef = B3BA65A21F5A269100B34850 /* SocketClient.swift */; };
|
@@ -42,6 +42,7 @@
|
|
42
42
|
/* Begin PBXFileReference section */
|
43
43
|
0311E386230AC1B20060BB5C /* Plugins.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; name = Plugins.swift; path = ../Plugins.swift; sourceTree = "<group>"; };
|
44
44
|
0311E38A230AC9490060BB5C /* Actions.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; name = Actions.swift; path = ../Actions.swift; sourceTree = "<group>"; };
|
45
|
+
1257253824B7992B00E04FA3 /* main.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; name = main.swift; path = ../main.swift; sourceTree = "<group>"; };
|
45
46
|
B30206741F5E3E9000DE6EBD /* SnapshotfileProtocol.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; name = SnapshotfileProtocol.swift; path = ../SnapshotfileProtocol.swift; sourceTree = "<group>"; };
|
46
47
|
B30206751F5E3E9000DE6EBD /* GymfileProtocol.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; name = GymfileProtocol.swift; path = ../GymfileProtocol.swift; sourceTree = "<group>"; };
|
47
48
|
B30206761F5E3E9000DE6EBD /* MatchfileProtocol.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; name = MatchfileProtocol.swift; path = ../MatchfileProtocol.swift; sourceTree = "<group>"; };
|
@@ -55,7 +56,6 @@
|
|
55
56
|
B3144C0A200553DC00470AFE /* README.txt */ = {isa = PBXFileReference; lastKnownFileType = text; path = README.txt; sourceTree = "<group>"; };
|
56
57
|
B3BA659D1F5A269100B34850 /* Fastlane.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; name = Fastlane.swift; path = ../Fastlane.swift; sourceTree = "<group>"; };
|
57
58
|
B3BA659E1F5A269100B34850 /* LaneFileProtocol.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; name = LaneFileProtocol.swift; path = ../LaneFileProtocol.swift; sourceTree = "<group>"; };
|
58
|
-
B3BA659F1F5A269100B34850 /* main.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; name = main.swift; path = ../main.swift; sourceTree = "<group>"; };
|
59
59
|
B3BA65A01F5A269100B34850 /* RubyCommand.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; name = RubyCommand.swift; path = ../RubyCommand.swift; sourceTree = "<group>"; };
|
60
60
|
B3BA65A11F5A269100B34850 /* Runner.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; name = Runner.swift; path = ../Runner.swift; sourceTree = "<group>"; };
|
61
61
|
B3BA65A21F5A269100B34850 /* SocketClient.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; name = SocketClient.swift; path = ../SocketClient.swift; sourceTree = "<group>"; };
|
@@ -161,9 +161,9 @@
|
|
161
161
|
D512BA011F7C7F40000D2137 /* Runner Code */ = {
|
162
162
|
isa = PBXGroup;
|
163
163
|
children = (
|
164
|
+
1257253824B7992B00E04FA3 /* main.swift */,
|
164
165
|
B3144C0A200553DC00470AFE /* README.txt */,
|
165
166
|
D5BAFD111F7DAAFC0030B324 /* ArgumentProcessor.swift */,
|
166
|
-
B3BA659F1F5A269100B34850 /* main.swift */,
|
167
167
|
B3BA65AE1F5A2D5C00B34850 /* RunnerArgument.swift */,
|
168
168
|
);
|
169
169
|
name = "Runner Code";
|
@@ -236,7 +236,7 @@
|
|
236
236
|
);
|
237
237
|
runOnlyForDeploymentPostprocessing = 0;
|
238
238
|
shellPath = /bin/sh;
|
239
|
-
shellScript = "cd \"${SRCROOT}\"\ncd ../..\ncp \"${TARGET_BUILD_DIR}/${EXECUTABLE_PATH}\"
|
239
|
+
shellScript = "cd \"${SRCROOT}\"\ncd ../..\ncp \"${TARGET_BUILD_DIR}/${EXECUTABLE_PATH}\" .\n";
|
240
240
|
};
|
241
241
|
/* End PBXShellScriptBuildPhase section */
|
242
242
|
|
@@ -267,9 +267,9 @@
|
|
267
267
|
B3BA65AA1F5A269100B34850 /* Runner.swift in Sources */,
|
268
268
|
B3BA65AF1F5A2D5C00B34850 /* RunnerArgument.swift in Sources */,
|
269
269
|
D5B8A5B31FFDC49E00536B24 /* ControlCommand.swift in Sources */,
|
270
|
+
1257253924B7992C00E04FA3 /* main.swift in Sources */,
|
270
271
|
B302067E1F5E3E9000DE6EBD /* PrecheckfileProtocol.swift in Sources */,
|
271
272
|
B3BA65AD1F5A269100B34850 /* SocketResponse.swift in Sources */,
|
272
|
-
B3BA65A81F5A269100B34850 /* main.swift in Sources */,
|
273
273
|
D55B28C71F6C588300DC42C5 /* Scanfile.swift in Sources */,
|
274
274
|
0311E387230AC1B20060BB5C /* Plugins.swift in Sources */,
|
275
275
|
D55B28C91F6C588300DC42C5 /* Snapshotfile.swift in Sources */,
|
@@ -1,3 +1,6 @@
|
|
1
|
+
// Gymfile.swift
|
2
|
+
// Copyright (c) 2020 FastlaneTools
|
3
|
+
|
1
4
|
// This class is automatically included in FastlaneRunner during build
|
2
5
|
|
3
6
|
// This autogenerated file will be overwritten or replaced during build time, or when you initialize `gym`
|
@@ -8,10 +11,10 @@
|
|
8
11
|
// new group so that it won't be marked for upgrade
|
9
12
|
//
|
10
13
|
|
11
|
-
class Gymfile: GymfileProtocol {
|
14
|
+
public class Gymfile: GymfileProtocol {
|
12
15
|
// If you want to enable `gym`, run `fastlane gym init`
|
13
16
|
// After, this file will be replaced with a custom implementation that contains values you supplied
|
14
17
|
// during the `init` process, and you won't see this message
|
15
18
|
}
|
16
19
|
|
17
|
-
// Generated with fastlane 2.
|
20
|
+
// Generated with fastlane 2.161.0
|
@@ -1,4 +1,7 @@
|
|
1
|
-
|
1
|
+
// GymfileProtocol.swift
|
2
|
+
// Copyright (c) 2020 FastlaneTools
|
3
|
+
|
4
|
+
public protocol GymfileProtocol: class {
|
2
5
|
/// Path to the workspace file
|
3
6
|
var workspace: String? { get }
|
4
7
|
|
@@ -132,7 +135,7 @@ protocol GymfileProtocol: class {
|
|
132
135
|
var clonedSourcePackagesPath: String? { get }
|
133
136
|
}
|
134
137
|
|
135
|
-
extension GymfileProtocol {
|
138
|
+
public extension GymfileProtocol {
|
136
139
|
var workspace: String? { return nil }
|
137
140
|
var project: String? { return nil }
|
138
141
|
var scheme: String? { return nil }
|
@@ -181,4 +184,4 @@ extension GymfileProtocol {
|
|
181
184
|
|
182
185
|
// Please don't remove the lines below
|
183
186
|
// They are used to detect outdated files
|
184
|
-
// FastlaneRunnerAPIVersion [0.9.
|
187
|
+
// FastlaneRunnerAPIVersion [0.9.47]
|
@@ -1,9 +1,5 @@
|
|
1
|
-
//
|
2
|
-
//
|
3
|
-
// FastlaneSwiftRunner
|
4
|
-
//
|
5
|
-
// Created by Joshua Liebowitz on 8/4/17.
|
6
|
-
//
|
1
|
+
// LaneFileProtocol.swift
|
2
|
+
// Copyright (c) 2020 FastlaneTools
|
7
3
|
|
8
4
|
//
|
9
5
|
// ** NOTE **
|
@@ -16,7 +12,7 @@ import Foundation
|
|
16
12
|
|
17
13
|
public protocol LaneFileProtocol: class {
|
18
14
|
var fastlaneVersion: String { get }
|
19
|
-
static func runLane(named: String, parameters: [String: String]) -> Bool
|
15
|
+
static func runLane(from fastfile: LaneFile?, named: String, parameters: [String: String]) -> Bool
|
20
16
|
|
21
17
|
func recordLaneDescriptions()
|
22
18
|
func beforeAll()
|
@@ -25,19 +21,19 @@ public protocol LaneFileProtocol: class {
|
|
25
21
|
}
|
26
22
|
|
27
23
|
public extension LaneFileProtocol {
|
28
|
-
var fastlaneVersion: String { return "" } //
|
29
|
-
func beforeAll() {} //
|
30
|
-
func afterAll(currentLane _: String) {} //
|
31
|
-
func onError(currentLane _: String, errorInfo _: String) {} //
|
32
|
-
func recordLaneDescriptions() {} //
|
24
|
+
var fastlaneVersion: String { return "" } // Defaults to "" because that means any is fine
|
25
|
+
func beforeAll() {} // No-op by default
|
26
|
+
func afterAll(currentLane _: String) {} // No-op by default
|
27
|
+
func onError(currentLane _: String, errorInfo _: String) {} // No-op by default
|
28
|
+
func recordLaneDescriptions() {} // No-op by default
|
33
29
|
}
|
34
30
|
|
35
31
|
@objcMembers
|
36
|
-
|
37
|
-
private(set) static var fastfileInstance:
|
32
|
+
open class LaneFile: NSObject, LaneFileProtocol {
|
33
|
+
private(set) static var fastfileInstance: LaneFile?
|
38
34
|
|
39
35
|
// Called before any lane is executed.
|
40
|
-
private func
|
36
|
+
private func setUpAllTheThings() {
|
41
37
|
LaneFile.fastfileInstance!.beforeAll()
|
42
38
|
}
|
43
39
|
|
@@ -52,7 +48,14 @@ public class LaneFile: NSObject, LaneFileProtocol {
|
|
52
48
|
private static var laneFunctionNames: [String] {
|
53
49
|
var lanes: [String] = []
|
54
50
|
var methodCount: UInt32 = 0
|
55
|
-
|
51
|
+
#if !SWIFT_PACKAGE
|
52
|
+
let methodList = class_copyMethodList(self, &methodCount)
|
53
|
+
#else
|
54
|
+
// In SPM we're calling this functions out of the scope of the normal binary that it's
|
55
|
+
// being built, so *self* in this scope would be the SPM executable instead of the Fastfile
|
56
|
+
// that we'd normally expect.
|
57
|
+
let methodList = class_copyMethodList(type(of: fastfileInstance!), &methodCount)
|
58
|
+
#endif
|
56
59
|
for i in 0 ..< Int(methodCount) {
|
57
60
|
let selName = sel_getName(method_getName(methodList![i]))
|
58
61
|
let name = String(cString: selName)
|
@@ -92,16 +95,26 @@ public class LaneFile: NSObject, LaneFileProtocol {
|
|
92
95
|
}
|
93
96
|
}
|
94
97
|
|
95
|
-
public static func runLane(named: String, parameters: [String: String]) -> Bool {
|
98
|
+
public static func runLane(from fastfile: LaneFile?, named: String, parameters: [String: String]) -> Bool {
|
96
99
|
log(message: "Running lane: \(named)")
|
97
|
-
|
98
|
-
|
99
|
-
|
100
|
-
let
|
101
|
-
|
102
|
-
|
103
|
-
|
104
|
-
|
100
|
+
#if !SWIFT_PACKAGE
|
101
|
+
// When not in SPM environment, we load the Fastfile from its `className()`.
|
102
|
+
loadFastfile()
|
103
|
+
guard let fastfileInstance: LaneFile = self.fastfileInstance else {
|
104
|
+
let message = "Unable to instantiate class named: \(className())"
|
105
|
+
log(message: message)
|
106
|
+
fatalError(message)
|
107
|
+
}
|
108
|
+
#else
|
109
|
+
// When in SPM environment, we can't load the Fastfile from its `className()` because the executable is in
|
110
|
+
// another scope, so `className()` won't be the expected Fastfile. Instead, we load the Fastfile as a Lanefile
|
111
|
+
// in a static way, by parameter.
|
112
|
+
guard let fastfileInstance: LaneFile = fastfile else {
|
113
|
+
log(message: "Found nil instance of fastfile")
|
114
|
+
preconditionFailure()
|
115
|
+
}
|
116
|
+
self.fastfileInstance = fastfileInstance
|
117
|
+
#endif
|
105
118
|
let currentLanes = lanes
|
106
119
|
let lowerCasedLaneRequested = named.lowercased()
|
107
120
|
|
@@ -122,13 +135,13 @@ public class LaneFile: NSObject, LaneFileProtocol {
|
|
122
135
|
return false
|
123
136
|
}
|
124
137
|
|
125
|
-
//
|
126
|
-
fastfileInstance.
|
138
|
+
// Call all methods that need to be called before we start calling lanes.
|
139
|
+
fastfileInstance.setUpAllTheThings()
|
127
140
|
|
128
|
-
// We need to catch all possible errors here and display a nice message
|
141
|
+
// We need to catch all possible errors here and display a nice message.
|
129
142
|
_ = fastfileInstance.perform(NSSelectorFromString(laneMethod), with: parameters)
|
130
143
|
|
131
|
-
// only
|
144
|
+
// Call only on success.
|
132
145
|
fastfileInstance.afterAll(currentLane: named)
|
133
146
|
log(message: "Done running lane: \(named) 🚀")
|
134
147
|
return true
|
@@ -0,0 +1,77 @@
|
|
1
|
+
// MainProcess.swift
|
2
|
+
// Copyright (c) 2020 FastlaneTools
|
3
|
+
|
4
|
+
//
|
5
|
+
// ** NOTE **
|
6
|
+
// This file is provided by fastlane and WILL be overwritten in future updates
|
7
|
+
// If you want to add extra functionality to this project, create a new file in a
|
8
|
+
// new group so that it won't be marked for upgrade
|
9
|
+
//
|
10
|
+
|
11
|
+
import Foundation
|
12
|
+
#if canImport(SwiftShell)
|
13
|
+
import SwiftShell
|
14
|
+
#endif
|
15
|
+
|
16
|
+
let argumentProcessor = ArgumentProcessor(args: CommandLine.arguments)
|
17
|
+
let timeout = argumentProcessor.commandTimeout
|
18
|
+
|
19
|
+
class MainProcess {
|
20
|
+
var doneRunningLane = false
|
21
|
+
var thread: Thread!
|
22
|
+
#if SWIFT_PACKAGE
|
23
|
+
var lastPrintDate = Date.distantFuture
|
24
|
+
var timeBetweenPrints = Int.min
|
25
|
+
var rubySocketCommand: AsyncCommand!
|
26
|
+
#endif
|
27
|
+
|
28
|
+
@objc func connectToFastlaneAndRunLane(_ fastfile: LaneFile?) {
|
29
|
+
runner.startSocketThread(port: argumentProcessor.port)
|
30
|
+
|
31
|
+
let completedRun = Fastfile.runLane(from: fastfile, named: argumentProcessor.currentLane, parameters: argumentProcessor.laneParameters())
|
32
|
+
if completedRun {
|
33
|
+
runner.disconnectFromFastlaneProcess()
|
34
|
+
}
|
35
|
+
|
36
|
+
doneRunningLane = true
|
37
|
+
}
|
38
|
+
|
39
|
+
func startFastlaneThread(with fastFile: LaneFile?) {
|
40
|
+
#if !SWIFT_PACKAGE
|
41
|
+
thread = Thread(target: self, selector: #selector(connectToFastlaneAndRunLane), object: nil)
|
42
|
+
#else
|
43
|
+
thread = Thread(target: self, selector: #selector(connectToFastlaneAndRunLane), object: fastFile)
|
44
|
+
#endif
|
45
|
+
thread.name = "worker thread"
|
46
|
+
#if SWIFT_PACKAGE
|
47
|
+
let PATH = run("/bin/bash", "-c", "-l", "eval $(/usr/libexec/path_helper -s) ; echo $PATH").stdout
|
48
|
+
main.env["PATH"] = PATH
|
49
|
+
let path = main.run(bash: "which fastlane").stdout
|
50
|
+
let pids = main.run("lsof", "-t", "-i", ":2000").stdout.split(separator: "\n")
|
51
|
+
pids.forEach { main.run("kill", "-9", $0) }
|
52
|
+
rubySocketCommand = main.runAsync(path, "socket_server", "-c", "1200")
|
53
|
+
lastPrintDate = Date()
|
54
|
+
rubySocketCommand.stderror.onStringOutput { print($0) }
|
55
|
+
rubySocketCommand.stdout.onStringOutput { stdout in
|
56
|
+
print(stdout)
|
57
|
+
self.timeBetweenPrints = Int(self.lastPrintDate.timeIntervalSinceNow)
|
58
|
+
}
|
59
|
+
_ = Runner.waitWithPolling(self.timeBetweenPrints, toEventually: { $0 > 5 }, timeout: 10)
|
60
|
+
thread.start()
|
61
|
+
#endif
|
62
|
+
}
|
63
|
+
}
|
64
|
+
|
65
|
+
public class Main {
|
66
|
+
let process = MainProcess()
|
67
|
+
|
68
|
+
public init() {}
|
69
|
+
|
70
|
+
public func run(with fastFile: LaneFile?) {
|
71
|
+
process.startFastlaneThread(with: fastFile)
|
72
|
+
|
73
|
+
while !process.doneRunningLane, RunLoop.current.run(mode: RunLoopMode.defaultRunLoopMode, before: Date(timeIntervalSinceNow: 2)) {
|
74
|
+
// no op
|
75
|
+
}
|
76
|
+
}
|
77
|
+
}
|
@@ -1,3 +1,6 @@
|
|
1
|
+
// Matchfile.swift
|
2
|
+
// Copyright (c) 2020 FastlaneTools
|
3
|
+
|
1
4
|
// This class is automatically included in FastlaneRunner during build
|
2
5
|
|
3
6
|
// This autogenerated file will be overwritten or replaced during build time, or when you initialize `match`
|
@@ -8,10 +11,10 @@
|
|
8
11
|
// new group so that it won't be marked for upgrade
|
9
12
|
//
|
10
13
|
|
11
|
-
class Matchfile: MatchfileProtocol {
|
14
|
+
public class Matchfile: MatchfileProtocol {
|
12
15
|
// If you want to enable `match`, run `fastlane match init`
|
13
16
|
// After, this file will be replaced with a custom implementation that contains values you supplied
|
14
17
|
// during the `init` process, and you won't see this message
|
15
18
|
}
|
16
19
|
|
17
|
-
// Generated with fastlane 2.
|
20
|
+
// Generated with fastlane 2.161.0
|
@@ -1,4 +1,7 @@
|
|
1
|
-
|
1
|
+
// MatchfileProtocol.swift
|
2
|
+
// Copyright (c) 2020 FastlaneTools
|
3
|
+
|
4
|
+
public protocol MatchfileProtocol: class {
|
2
5
|
/// Define the profile type, can be appstore, adhoc, development, enterprise, developer_id
|
3
6
|
var type: String { get }
|
4
7
|
|
@@ -50,7 +53,7 @@ protocol MatchfileProtocol: class {
|
|
50
53
|
/// Use a basic authorization header to access the git repo (e.g.: access via HTTPS, GitHub Actions, etc), usually a string in Base64
|
51
54
|
var gitBasicAuthorization: String? { get }
|
52
55
|
|
53
|
-
/// Use a bearer authorization header to access the git repo (e.g.: access to an Azure
|
56
|
+
/// Use a bearer authorization header to access the git repo (e.g.: access to an Azure DevOps repository), usually a string in Base64
|
54
57
|
var gitBearerAuthorization: String? { get }
|
55
58
|
|
56
59
|
/// Use a private key to access the git repo (e.g.: access to GitHub repository via Deploy keys), usually a id_rsa named file or the contents hereof
|
@@ -120,7 +123,7 @@ protocol MatchfileProtocol: class {
|
|
120
123
|
var verbose: Bool { get }
|
121
124
|
}
|
122
125
|
|
123
|
-
extension MatchfileProtocol {
|
126
|
+
public extension MatchfileProtocol {
|
124
127
|
var type: String { return "development" }
|
125
128
|
var additionalCertTypes: [String]? { return nil }
|
126
129
|
var readonly: Bool { return false }
|
@@ -165,4 +168,4 @@ extension MatchfileProtocol {
|
|
165
168
|
|
166
169
|
// Please don't remove the lines below
|
167
170
|
// They are used to detect outdated files
|
168
|
-
// FastlaneRunnerAPIVersion [0.9.
|
171
|
+
// FastlaneRunnerAPIVersion [0.9.41]
|
@@ -1,3 +1,6 @@
|
|
1
|
+
// Precheckfile.swift
|
2
|
+
// Copyright (c) 2020 FastlaneTools
|
3
|
+
|
1
4
|
// This class is automatically included in FastlaneRunner during build
|
2
5
|
|
3
6
|
// This autogenerated file will be overwritten or replaced during build time, or when you initialize `precheck`
|
@@ -8,10 +11,10 @@
|
|
8
11
|
// new group so that it won't be marked for upgrade
|
9
12
|
//
|
10
13
|
|
11
|
-
class Precheckfile: PrecheckfileProtocol {
|
14
|
+
public class Precheckfile: PrecheckfileProtocol {
|
12
15
|
// If you want to enable `precheck`, run `fastlane precheck init`
|
13
16
|
// After, this file will be replaced with a custom implementation that contains values you supplied
|
14
17
|
// during the `init` process, and you won't see this message
|
15
18
|
}
|
16
19
|
|
17
|
-
// Generated with fastlane 2.
|
20
|
+
// Generated with fastlane 2.161.0
|
@@ -1,4 +1,13 @@
|
|
1
|
-
|
1
|
+
// PrecheckfileProtocol.swift
|
2
|
+
// Copyright (c) 2020 FastlaneTools
|
3
|
+
|
4
|
+
public protocol PrecheckfileProtocol: class {
|
5
|
+
/// Path to your App Store Connect API Key JSON file (https://docs.fastlane.tools/app-store-connect-api/#using-fastlane-api-key-json-file)
|
6
|
+
var apiKeyPath: String? { get }
|
7
|
+
|
8
|
+
/// Your App Store Connect API Key information (https://docs.fastlane.tools/app-store-connect-api/#use-return-value-and-pass-in-as-an-option)
|
9
|
+
var apiKey: [String: Any]? { get }
|
10
|
+
|
2
11
|
/// The bundle identifier of your app
|
3
12
|
var appIdentifier: String { get }
|
4
13
|
|
@@ -11,6 +20,9 @@ protocol PrecheckfileProtocol: class {
|
|
11
20
|
/// The name of your App Store Connect team if you're in multiple teams
|
12
21
|
var teamName: String? { get }
|
13
22
|
|
23
|
+
/// The platform to use (optional)
|
24
|
+
var platform: String { get }
|
25
|
+
|
14
26
|
/// The default rule level unless otherwise configured
|
15
27
|
var defaultRuleLevel: String { get }
|
16
28
|
|
@@ -21,11 +33,14 @@ protocol PrecheckfileProtocol: class {
|
|
21
33
|
var freeStuffInIap: String? { get }
|
22
34
|
}
|
23
35
|
|
24
|
-
extension PrecheckfileProtocol {
|
36
|
+
public extension PrecheckfileProtocol {
|
37
|
+
var apiKeyPath: String? { return nil }
|
38
|
+
var apiKey: [String: Any]? { return nil }
|
25
39
|
var appIdentifier: String { return "" }
|
26
40
|
var username: String { return "" }
|
27
41
|
var teamId: String? { return nil }
|
28
42
|
var teamName: String? { return nil }
|
43
|
+
var platform: String { return "ios" }
|
29
44
|
var defaultRuleLevel: String { return "error" }
|
30
45
|
var includeInAppPurchases: Bool { return true }
|
31
46
|
var freeStuffInIap: String? { return nil }
|
@@ -33,4 +48,4 @@ extension PrecheckfileProtocol {
|
|
33
48
|
|
34
49
|
// Please don't remove the lines below
|
35
50
|
// They are used to detect outdated files
|
36
|
-
// FastlaneRunnerAPIVersion [0.9.
|
51
|
+
// FastlaneRunnerAPIVersion [0.9.40]
|