@@ -43,9 +43,15 @@ public extension XCScheme {
4343 public var launchStyle : Style
4444 public var askForAppToLaunch : Bool ?
4545 public var pathRunnable : PathRunnable ? {
46- // For backwards compatibility
47- runnable as? PathRunnable
46+ // For backwards compatibility
47+ get {
48+ runnable as? PathRunnable
49+ }
50+ set {
51+ self . pathRunnable = newValue
52+ }
4853 }
54+
4955 public var customWorkingDirectory : String ?
5056 public var useCustomWorkingDirectory : Bool
5157 public var ignoresPersistentStateOnLaunch : Bool
@@ -81,6 +87,7 @@ public extension XCScheme {
8187
8288 // MARK: - Init
8389
90+ @available ( * , deprecated, message: " Use the init() that consolidates pathRunnable and runnable into a single parameter. " )
8491 public init ( runnable: Runnable ? ,
8592 buildConfiguration: String ,
8693 preActions: [ ExecutionAction ] = [ ] ,
@@ -90,6 +97,7 @@ public extension XCScheme {
9097 selectedLauncherIdentifier: String = XCScheme . defaultLauncher,
9198 launchStyle: Style = . auto,
9299 askForAppToLaunch: Bool ? = nil ,
100+ pathRunnable _: PathRunnable ? = nil ,
93101 customWorkingDirectory: String ? = nil ,
94102 useCustomWorkingDirectory: Bool = false ,
95103 ignoresPersistentStateOnLaunch: Bool = false ,
@@ -163,7 +171,7 @@ public extension XCScheme {
163171 }
164172
165173 public convenience init (
166- runnable : Runnable ? ,
174+ pathRunnable : PathRunnable ? ,
167175 buildConfiguration: String ,
168176 preActions: [ ExecutionAction ] = [ ] ,
169177 postActions: [ ExecutionAction ] = [ ] ,
@@ -172,7 +180,6 @@ public extension XCScheme {
172180 selectedLauncherIdentifier: String = XCScheme . defaultLauncher,
173181 launchStyle: Style = . auto,
174182 askForAppToLaunch: Bool ? = nil ,
175- pathRunnable: PathRunnable ? = nil ,
176183 customWorkingDirectory: String ? = nil ,
177184 useCustomWorkingDirectory: Bool = false ,
178185 ignoresPersistentStateOnLaunch: Bool = false ,
@@ -206,7 +213,7 @@ public extension XCScheme {
206213 customLLDBInitFile: String ? = nil
207214 ) {
208215 self . init (
209- runnable: pathRunnable ?? runnable ,
216+ runnable: pathRunnable,
210217 buildConfiguration: buildConfiguration,
211218 preActions: preActions,
212219 postActions: postActions,
@@ -215,6 +222,7 @@ public extension XCScheme {
215222 selectedLauncherIdentifier: selectedLauncherIdentifier,
216223 launchStyle: launchStyle,
217224 askForAppToLaunch: askForAppToLaunch,
225+ pathRunnable: pathRunnable,
218226 customWorkingDirectory: customWorkingDirectory,
219227 useCustomWorkingDirectory: useCustomWorkingDirectory,
220228 ignoresPersistentStateOnLaunch: ignoresPersistentStateOnLaunch,
0 commit comments