mirror of
https://github.com/yonaskolb/XcodeGen.git
synced 2026-03-18 20:02:25 +00:00
Update for comments
This commit is contained in:
@@ -418,10 +418,19 @@ Schemes allows for more control than the convenience [Target Scheme](#target-sch
|
||||
- `analyze` or `analyzing`
|
||||
- `archive` or `archiving`
|
||||
|
||||
- [ ] **parallelizeBuild**: **Bool** - Whether or not your targets should be built in parallel.
|
||||
- `true`: Build targets in parallel
|
||||
- `false`: Build targets serially
|
||||
- [ ] **buildImplicitDependencies**: **Bool** - Flag to determine if Xcode should be implicit dependencies of this scheme.
|
||||
- `true`: Discover implicit dependencies of this scheme
|
||||
- `false`: Only build explicit dependencies of this scheme
|
||||
|
||||
```yaml
|
||||
targets:
|
||||
myTarget: all
|
||||
myTarget2: [test, run]
|
||||
parallelizeBuild: true
|
||||
buildImplicitDependencies: true
|
||||
```
|
||||
|
||||
### Common Build Action options
|
||||
|
||||
@@ -51,19 +51,19 @@ public struct Scheme: Equatable {
|
||||
|
||||
public struct Build: Equatable {
|
||||
public var targets: [BuildTarget]
|
||||
public var parallelizeBuildables: Bool
|
||||
public var parallelizeBuild: Bool
|
||||
public var buildImplicitDependencies: Bool
|
||||
public var preActions: [ExecutionAction]
|
||||
public var postActions: [ExecutionAction]
|
||||
public init(
|
||||
targets: [BuildTarget],
|
||||
parallelizeBuildables: Bool = true,
|
||||
parallelizeBuild: Bool = true,
|
||||
buildImplicitDependencies: Bool = true,
|
||||
preActions: [ExecutionAction] = [],
|
||||
postActions: [ExecutionAction] = []
|
||||
) {
|
||||
self.targets = targets
|
||||
self.parallelizeBuildables = parallelizeBuildables
|
||||
self.parallelizeBuild = parallelizeBuild
|
||||
self.buildImplicitDependencies = buildImplicitDependencies
|
||||
self.preActions = preActions
|
||||
self.postActions = postActions
|
||||
@@ -316,7 +316,7 @@ extension Scheme.Build: JSONObjectConvertible {
|
||||
self.targets = targets.sorted { $0.target < $1.target }
|
||||
preActions = try jsonDictionary.json(atKeyPath: "preActions")?.map(Scheme.ExecutionAction.init) ?? []
|
||||
postActions = try jsonDictionary.json(atKeyPath: "postActions")?.map(Scheme.ExecutionAction.init) ?? []
|
||||
parallelizeBuildables = jsonDictionary.json(atKeyPath: "parallelizeBuildables") ?? true
|
||||
parallelizeBuild = jsonDictionary.json(atKeyPath: "parallelizeBuild") ?? true
|
||||
buildImplicitDependencies = jsonDictionary.json(atKeyPath: "buildImplicitDependencies") ?? true
|
||||
}
|
||||
}
|
||||
|
||||
@@ -78,7 +78,7 @@ public class ProjectGenerator {
|
||||
buildActionEntries: buildActionEntries,
|
||||
preActions: scheme.build.preActions.map(getExecutionAction),
|
||||
postActions: scheme.build.postActions.map(getExecutionAction),
|
||||
parallelizeBuild: scheme.build.parallelizeBuildables,
|
||||
parallelizeBuild: scheme.build.parallelizeBuild,
|
||||
buildImplicitDependencies: scheme.build.buildImplicitDependencies
|
||||
)
|
||||
|
||||
|
||||
@@ -157,7 +157,7 @@ func specLoadingTests() {
|
||||
$0.it("parses schemes") {
|
||||
let schemeDictionary: [String: Any] = [
|
||||
"build": [
|
||||
"parallelizeBuildables": false,
|
||||
"parallelizeBuild": false,
|
||||
"buildImplicitDependencies": false,
|
||||
"targets": [
|
||||
"Target1": "all",
|
||||
@@ -191,7 +191,7 @@ func specLoadingTests() {
|
||||
try expect(scheme.build.preActions.first?.name) == "Before Build"
|
||||
try expect(scheme.build.preActions.first?.settingsTarget) == "Target1"
|
||||
|
||||
try expect(scheme.build.parallelizeBuildables) == false
|
||||
try expect(scheme.build.parallelizeBuild) == false
|
||||
try expect(scheme.build.buildImplicitDependencies) == false
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user