rork-xcode 0.2.0 → 0.4.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.
package/README.md CHANGED
@@ -3,7 +3,7 @@
3
3
  [![CI](https://github.com/rorkai/rork-xcode/actions/workflows/ci.yml/badge.svg)](https://github.com/rorkai/rork-xcode/actions/workflows/ci.yml)
4
4
  [![npm](https://img.shields.io/npm/v/rork-xcode)](https://www.npmjs.com/package/rork-xcode)
5
5
 
6
- The [fastest](#performance) zero-dependency Xcode project (`project.pbxproj`) parser, builder, and object model for any JavaScript runtime: browsers, Node.js, Bun, Electron, Cloudflare Workers, and React Native.
6
+ The [fastest](#performance) zero-dependency Xcode project (`project.pbxproj`) parser, builder, and object model for any JavaScript runtime: browsers, Node.js, Bun, Electron, Cloudflare Workers, and React Native. [Scheme files](#schemes) (`.xcscheme`) are covered with the same round-trip guarantees.
7
7
 
8
8
  ```ts
9
9
  import { parsePbxproj, buildPbxproj } from "rork-xcode";
@@ -25,11 +25,11 @@ const text = buildPbxproj(project); // byte-stable, Xcode-canonical layout
25
25
 
26
26
  `rork-xcode` is designed for exactly that situation:
27
27
 
28
- - **Zero dependencies.** The pbxproj grammar is a small OpenStep-style property list dialect: dictionaries, arrays, strings, and hex data runs. A dedicated scanner covers it completely, with no general-purpose parser stack, no native addon, and no WASM blob.
28
+ - **Zero dependencies.** The pbxproj grammar is a small OpenStep-style property list dialect of dictionaries, arrays, strings, and hex data runs. A dedicated scanner covers it completely, with no general-purpose parser stack, no native addon, and no WASM blob.
29
29
  - **One artifact, one code path.** A single ESM file with named exports. No environment-conditional entry points, no reliance on ambient globals like `Buffer`. What you test locally is what runs in production, whatever the bundler.
30
30
  - **Xcode-canonical output.** The serializer reproduces the layout Xcode itself writes (tab indentation, per-isa object sections in sorted order, single-line build-file entries, and derived reference comments like `13B07F86… /* AppDelegate.swift in Sources */`), so diffs against Xcode-saved projects stay minimal and Xcode does not rewrite the file on next save.
31
31
  - **Round-trip faithful.** Parse → build is byte-identical for Xcode-canonical documents and a fixed point for everything else. Lexical subtleties that plain number conversion would destroy (leading-zero values like `0755`, trailing-zero versions like `5.0`, digit runs longer than the double-precision safe range) are preserved as strings by design.
32
- - **Loud failure modes.** Malformed documents fail with a typed error carrying line and column; unrepresentable values (`null`, booleans, non-finite numbers) fail with the exact path of the offending value. Nothing is silently dropped.
32
+ - **Loud failure modes.** Malformed documents fail with a typed error carrying line and column, and unrepresentable values (`null`, booleans, non-finite numbers) fail with the exact path of the offending value. Nothing is silently dropped.
33
33
 
34
34
  ## Install
35
35
 
@@ -222,13 +222,49 @@ for (const [id, object] of project.objects()) {
222
222
 
223
223
  ### Semantics
224
224
 
225
- - **Typed vocabulary, generic fallback.** The typed views cover targets of every kind, groups and variant groups, Xcode 16 synchronized folders and their exception sets, build phases and build rules, Core Data version groups, and cross-project reference proxies. Every other kind is a generic `XcodeObject` with the same read and write access, so nothing in a document is out of reach.
225
+ - **Typed vocabulary, generic fallback.** The typed views cover targets of every kind, groups and variant groups, Xcode 16 synchronized folders and their exception sets, build phases and build rules, build configurations, file references, container item proxies, Core Data version groups, and cross-project reference proxies. Every other kind is a generic `XcodeObject` with the same read and write access, so nothing in a document is out of reach.
226
+ - **`is()` narrowing.** Every view class carries a static type guard for discriminating mixed objects: `if (NativeTarget.is(object))` narrows the way `instanceof` does, subclasses included. Build configurations additionally expose their settings as a live typed dictionary through `configuration.buildSettings`.
226
227
  - **Typed, open property shapes.** Known keys autocomplete (`target.properties.productType`) and the shape stays open, so keys like `INFOPLIST_KEY_*` settings remain first-class. The shapes describe well-formed documents. When reading untrusted input, use the narrowing accessors, which never trust them.
227
- - **Two verb families.** `add*` wires something to its owner (a dependency, a package, a framework, a synchronized folder) and is idempotent: re-adding returns the existing wiring. `ensure*` returns a structural container, creating it when missing (a build phase, a group chain, the Products group). Both families can therefore run unconditionally in scaffold and repair flows.
228
+ - **Two verb families.** `add*` wires something to its owner (a dependency, a package, a framework, a synchronized folder) and is idempotent, so re-adding returns the existing wiring. `ensure*` returns a structural container, creating it when missing (a build phase, a group chain, the Products group). Both families can therefore run unconditionally in scaffold and repair flows.
228
229
  - **Deterministic identifiers.** New objects get ids derived from what they are (`XX` + 20 digest characters + `XX`, from an embedded hash), so programmatic edits are reproducible run to run and diffs stay minimal. Collisions within a document resolve deterministically, and identical edit sequences produce byte-identical documents.
229
230
  - **Soft reads, loud writes.** Real-world projects can be malformed, so lookups return `undefined` where a document could omit something. Operations that cannot proceed without structure (no root project object, an unknown product type, a view whose object was deleted) throw `XcodeModelError`.
230
231
  - **Identity-mapped views.** Two lookups of the same id return the same instance, so views compare with `===`.
231
232
 
233
+ ## Schemes
234
+
235
+ `.xcscheme` files describe how Xcode builds, runs, tests, and archives a target. They are not property lists but a small XML dialect of their own, and the scheme module covers it with the same contract as the pbxproj functions. An Xcode-written scheme rebuilds byte for byte, any other input reaches Xcode's canonical layout in one build, and malformed input fails with a typed error carrying line and column.
236
+
237
+ `Xcscheme` is the model. Buildable references are the elements editing flows touch, and they come back as typed views:
238
+
239
+ ```ts
240
+ import { Xcscheme } from "rork-xcode";
241
+
242
+ const scheme = Xcscheme.parse(xcschemeText);
243
+
244
+ // Rename the app while keeping each product's own shape, so a testable
245
+ // like DemoAppTests.xctest stays a test bundle.
246
+ for (const reference of scheme.buildableReferences()) {
247
+ const { blueprintName, buildableName } = reference;
248
+ if (blueprintName) reference.blueprintName = blueprintName.replace("DemoApp", "RenamedApp");
249
+ if (buildableName) reference.buildableName = buildableName.replace("DemoApp", "RenamedApp");
250
+ reference.referencedContainer = "container:RenamedApp.xcodeproj";
251
+ }
252
+
253
+ const text = scheme.build();
254
+ ```
255
+
256
+ `Xcscheme.create` produces the scheme Xcode's own "New Scheme" action writes for an application target, wired to the target's object id from the project document:
257
+
258
+ ```ts
259
+ const scheme = Xcscheme.create({
260
+ appName: "DemoApp",
261
+ blueprintIdentifier: app.id,
262
+ });
263
+ const text = scheme.build();
264
+ ```
265
+
266
+ Underneath, the document is a plain tree of elements with ordered attributes and children, reachable through `scheme.root` and `scheme.elements(name)`, so anything the typed surface does not cover stays one property away. `parseXcscheme` and `buildXcscheme` remain available for working with the tree directly. Attribute order is preserved and meaningful, which is how byte-identical round-trips fall out. Comments are kept, attribute values resolve the character references Xcode writes (`"`, `&`, `
` and friends), and the writer re-escapes them identically.
267
+
232
268
  ## Performance
233
269
 
234
270
  `rork-xcode` is measured against the pbxproj parsers on npm, [`@bacons/xcode`](https://www.npmjs.com/package/@bacons/xcode) (its `/json` parse/build entry point) and [`xcode`](https://www.npmjs.com/package/xcode) (the long-standing package used by native build tooling), on three documents: two real Xcode-written projects from the test suite and a deterministically generated five-target app with 800 source files. It is the fastest at both operations on every document, with zero dependencies.
@@ -250,8 +286,8 @@ Measured on an Apple M5 Max, Node.js 24, single thread, with `@bacons/xcode` 1.0
250
286
 
251
287
  ### Key performance features
252
288
 
253
- - **Single-pass scanner.** One cursor over the input string with table-driven character classification; no tokenizer stage, no intermediate token objects.
254
- - **Comments skip in bulk.** Reference comments are a sizable share of a canonical document's bytes; comment bodies are jumped with `indexOf` instead of being scanned per character.
289
+ - **Single-pass scanner.** One cursor over the input string with table-driven character classification. There is no tokenizer stage and no intermediate token objects.
290
+ - **Comments skip in bulk.** Reference comments are a sizable share of a canonical document's bytes, so comment bodies are jumped with `indexOf` instead of being scanned per character.
255
291
  - **Linear comment derivation.** Building the `/* … */` annotations uses reverse indexes over the object graph (build file → phase, configuration list → owner), so serialization stays linear on projects with thousands of objects.
256
292
  - **Memoized rendering.** Quoting decisions for the repeated key vocabulary and rendered uuid references are cached per document, halving the quote scans on reference-heavy sections.
257
293
 
@@ -260,7 +296,7 @@ Measured on an Apple M5 Max, Node.js 24, single thread, with `@bacons/xcode` 1.0
260
296
  - The committed fixture corpus spans project generations from Xcode 3 to Xcode 16, captured from real projects with identifiers neutralized: synchronized folders with both exception-set kinds, classic groups, variant groups, aggregate and legacy targets, reference proxies, build rules, Swift packages, and a ~100 KiB multiplatform framework project.
261
297
  - Documents already in current Xcode's layout must round-trip byte for byte; documents from other tool generations must normalize to a byte-stable fixed point with unchanged values.
262
298
  - On macOS, the suite cross-validates every fixture and its rebuilt form with `plutil`, Apple's own property list parser and the empirical ground truth for what Apple tooling accepts.
263
- - A corpus sweep (`pnpm corpus`) walks every Xcode project on the machine, verifies each one parses and reaches a byte-stable fixed point, exercises the object model against it, and cross-validates a sample against plutil's own reading.
299
+ - A corpus sweep (`pnpm corpus`) walks every Xcode project and scheme on the machine, verifies each one parses and reaches a byte-stable fixed point, exercises the object model against every project, and cross-validates a sample against plutil's own reading.
264
300
  - CI runs the full gate on Linux and macOS, and executes the built artifact on the oldest supported Node to enforce the `engines` floor.
265
301
 
266
302
  ## Releasing
package/dist/index.d.ts CHANGED
@@ -114,6 +114,42 @@ declare class PbxprojParseError extends Error {
114
114
  */
115
115
  constructor(message: string, source: string, offset: number);
116
116
  }
117
+ /**
118
+ * Thrown when the source text is not a well-formed scheme document (the
119
+ * XML dialect of `.xcscheme` files).
120
+ *
121
+ * The message always embeds the line and column of the failure, and the
122
+ * same information is available in structured form on {@link position}
123
+ * for programmatic use.
124
+ */
125
+ declare class XcschemeParseError extends Error {
126
+ /** Where in the source text parsing failed. */
127
+ readonly position: PbxprojErrorPosition;
128
+ /**
129
+ * @param message Failure description without location; the location is
130
+ * appended automatically.
131
+ * @param source Full source text, used to compute the position.
132
+ * @param offset Character offset of the failure inside `source`.
133
+ */
134
+ constructor(message: string, source: string, offset: number);
135
+ }
136
+ /**
137
+ * Thrown when a scheme element cannot be written as XML.
138
+ *
139
+ * Raised for element and attribute names that are not valid XML names and
140
+ * for attribute values carrying control characters XML 1.0 cannot encode.
141
+ * The {@link path} pinpoints the offending element inside the tree.
142
+ */
143
+ declare class XcschemeBuildError extends Error {
144
+ /** Path to the offending element from the root, e.g. `Scheme.BuildAction[0]`. */
145
+ readonly path: string;
146
+ /**
147
+ * @param message Failure description without location; the element path
148
+ * is appended automatically.
149
+ * @param path Path to the offending element from the root.
150
+ */
151
+ constructor(message: string, path: string);
152
+ }
117
153
  /**
118
154
  * Thrown by the object model when an operation cannot proceed: the
119
155
  * document lacks the structure the operation needs (no objects dictionary,
@@ -271,6 +307,8 @@ interface BuildSettings extends PbxprojObject {
271
307
  SUPPORTED_PLATFORMS?: string;
272
308
  SWIFT_VERSION?: string;
273
309
  TARGETED_DEVICE_FAMILY?: number | string;
310
+ TEST_HOST?: string;
311
+ TEST_TARGET_NAME?: string;
274
312
  TVOS_DEPLOYMENT_TARGET?: string;
275
313
  WATCHOS_DEPLOYMENT_TARGET?: string;
276
314
  XROS_DEPLOYMENT_TARGET?: string;
@@ -852,6 +890,49 @@ declare class VersionGroup extends Group<VersionGroupProperties> {
852
890
  */
853
891
  setCurrentVersion(reference: XcodeObject): void;
854
892
  }
893
+ /**
894
+ * An `XCBuildConfiguration` holds one named settings dictionary of a
895
+ * target or of the project, for example Debug or Release.
896
+ */
897
+ declare class BuildConfiguration extends XcodeObject<BuildConfigurationProperties> {
898
+ /**
899
+ * The configuration's name, when present.
900
+ */
901
+ get name(): string | undefined;
902
+ /**
903
+ * The configuration's settings dictionary, typed with the keys
904
+ * programmatic edits touch most, or `undefined` when the configuration
905
+ * carries none. The dictionary is live. Writes through it land in the
906
+ * document.
907
+ */
908
+ get buildSettings(): BuildSettings | undefined;
909
+ }
910
+ /**
911
+ * A `PBXFileReference` names one file on disk, from source files to the
912
+ * built products themselves.
913
+ */
914
+ declare class FileReference extends XcodeObject<FileReferenceProperties> {
915
+ /**
916
+ * The reference's path, relative to its `sourceTree`, when present.
917
+ */
918
+ get path(): string | undefined;
919
+ /**
920
+ * The reference's display name, when it carries one distinct from the
921
+ * path.
922
+ */
923
+ get name(): string | undefined;
924
+ }
925
+ /**
926
+ * A `PBXContainerItemProxy` is the indirection Xcode places between a
927
+ * target dependency and the target it points at.
928
+ */
929
+ declare class ContainerItemProxy extends XcodeObject<ContainerItemProxyProperties> {
930
+ /**
931
+ * The display name of the object the proxy points at, when present.
932
+ * For target dependencies this is the target's name.
933
+ */
934
+ get remoteInfo(): string | undefined;
935
+ }
855
936
  /**
856
937
  * A `PBXReferenceProxy` stands in for a product built by a target of
857
938
  * another project referenced from this one.
@@ -1177,15 +1258,32 @@ declare class XcodeObject<Properties extends PbxprojObject = PbxprojObject> {
1177
1258
  /** The object's 24-character identifier (its key in `objects`). */
1178
1259
  readonly id: string;
1179
1260
  /**
1180
- * Views are created by the project's identity map; use
1261
+ * Views are created by the project's identity map. Use
1181
1262
  * {@link XcodeProject.get} or a typed query instead of constructing
1182
1263
  * views directly.
1183
1264
  */
1184
1265
  constructor(project: XcodeProject, id: string);
1185
1266
  /**
1186
- * The object's raw dictionary inside the document. Mutations through the
1187
- * model write here, and direct writes are equally valid; the model adds
1188
- * no caching over these properties.
1267
+ * Whether a value is a view of this class, narrowing it when so. Views
1268
+ * come typed out of the factory, and this is the readable way to
1269
+ * discriminate them when iterating mixed objects.
1270
+ *
1271
+ * ```ts
1272
+ * for (const [, object] of project.objects()) {
1273
+ * if (NativeTarget.is(object)) {
1274
+ * console.log(object.name);
1275
+ * }
1276
+ * }
1277
+ * ```
1278
+ *
1279
+ * Subclass views match their parent class too, the way `instanceof`
1280
+ * does, so a `VersionGroup` is a `Group`.
1281
+ */
1282
+ static is<Constructor extends abstract new (...args: never) => unknown>(this: Constructor, value: unknown): value is InstanceType<Constructor>;
1283
+ /**
1284
+ * The object's raw dictionary inside the document. Mutations through
1285
+ * the model write here, direct writes are equally valid, and the model
1286
+ * adds no caching over these properties.
1189
1287
  *
1190
1288
  * The typed shape is asserted, not checked. It describes what a
1191
1289
  * well-formed object of this kind carries (see `properties.ts`).
@@ -1245,6 +1343,210 @@ declare class XcodeObject<Properties extends PbxprojObject = PbxprojObject> {
1245
1343
  */
1246
1344
  declare function parsePbxproj(text: string): PbxprojValue;
1247
1345
  //#endregion
1346
+ //#region src/scheme/types.d.ts
1347
+ /**
1348
+ * The node model of a scheme document.
1349
+ *
1350
+ * A parsed `.xcscheme` is a tree of plain objects. Elements carry ordered
1351
+ * attributes and child nodes, and comments survive as their own nodes.
1352
+ * All state lives in this tree. There is no wrapper to keep in sync, so
1353
+ * callers mutate nodes directly and serialize whatever the tree currently
1354
+ * says.
1355
+ *
1356
+ * @module
1357
+ */
1358
+ /**
1359
+ * An XML element of a scheme document.
1360
+ *
1361
+ * Attribute order is preserved and meaningful. The writer emits
1362
+ * attributes in insertion order, which is how Xcode-written files
1363
+ * round-trip byte-identically. Assigning an existing key keeps its
1364
+ * position, and adding a new key appends it.
1365
+ */
1366
+ interface XcschemeElement {
1367
+ /** Tag name, for example `Scheme` or `BuildableReference`. */
1368
+ name: string;
1369
+ /** Attribute values by name, in document order. */
1370
+ attributes: Record<string, string>;
1371
+ /** Child elements and comments, in document order. */
1372
+ children: XcschemeNode[];
1373
+ }
1374
+ /**
1375
+ * A comment inside a scheme document. Xcode never writes comments, but
1376
+ * hand-edited and tool-generated schemes can carry them, and dropping
1377
+ * them would make round-trips lossy.
1378
+ */
1379
+ interface XcschemeComment {
1380
+ /** The comment text between `<!--` and `-->`, verbatim. */
1381
+ comment: string;
1382
+ }
1383
+ /**
1384
+ * Any node a scheme element can contain.
1385
+ */
1386
+ type XcschemeNode = XcschemeElement | XcschemeComment;
1387
+ /**
1388
+ * A parsed scheme file, made of its root element plus any comments
1389
+ * sitting outside it. Xcode writes only the root, so the comment lists
1390
+ * are almost always empty, but files that carry them round-trip without
1391
+ * loss.
1392
+ */
1393
+ interface XcschemeDocument {
1394
+ /** Comments before the root element. */
1395
+ leading: XcschemeComment[];
1396
+ /** The `Scheme` element. */
1397
+ root: XcschemeElement;
1398
+ /** Comments after the root element. */
1399
+ trailing: XcschemeComment[];
1400
+ }
1401
+ /**
1402
+ * Whether a node is an element rather than a comment.
1403
+ */
1404
+ declare function isXcschemeElement(node: XcschemeNode): node is XcschemeElement;
1405
+ //#endregion
1406
+ //#region src/scheme/build.d.ts
1407
+ /**
1408
+ * Serializes a scheme document to the text of a `.xcscheme` file.
1409
+ *
1410
+ * @throws XcschemeBuildError for element or attribute names that are not
1411
+ * XML names and for attribute values carrying unencodable control
1412
+ * characters, with the path of the offending node.
1413
+ */
1414
+ declare function buildXcscheme(document: XcschemeDocument): string;
1415
+ //#endregion
1416
+ //#region src/scheme/model.d.ts
1417
+ /**
1418
+ * Collects elements of the given name anywhere in the tree, in document
1419
+ * order, the subtree root included. Passing no name collects every
1420
+ * element.
1421
+ */
1422
+ declare function xcschemeElements(root: XcschemeElement, name?: string): XcschemeElement[];
1423
+ /**
1424
+ * A `BuildableReference` element with property-style attribute access.
1425
+ *
1426
+ * Buildable references are the elements editing flows touch most, since
1427
+ * every action points at its target through one. The view reads and
1428
+ * writes the element's attributes directly, so it never goes stale and
1429
+ * needs no separate save step.
1430
+ */
1431
+ declare class BuildableReference {
1432
+ /** The underlying element inside the document tree. */
1433
+ readonly element: XcschemeElement;
1434
+ constructor(element: XcschemeElement);
1435
+ /**
1436
+ * The referenced target's object id in the project document, when
1437
+ * present. Xcode repairs a missing or stale identifier on first open.
1438
+ */
1439
+ get blueprintIdentifier(): string | undefined;
1440
+ set blueprintIdentifier(value: string);
1441
+ /**
1442
+ * The referenced target's name, when present.
1443
+ */
1444
+ get blueprintName(): string | undefined;
1445
+ set blueprintName(value: string);
1446
+ /**
1447
+ * The built product's file name, for example `DemoApp.app`, when
1448
+ * present.
1449
+ */
1450
+ get buildableName(): string | undefined;
1451
+ set buildableName(value: string);
1452
+ /**
1453
+ * The container the target lives in, for example
1454
+ * `container:DemoApp.xcodeproj`, when present.
1455
+ */
1456
+ get referencedContainer(): string | undefined;
1457
+ set referencedContainer(value: string);
1458
+ }
1459
+ /**
1460
+ * A scheme document with typed access to the elements editing flows
1461
+ * touch.
1462
+ *
1463
+ * The model is a thin layer over the node tree. All state lives in the
1464
+ * document itself, and {@link build} serializes whatever the tree
1465
+ * currently says, so typed edits and direct tree edits compose freely.
1466
+ *
1467
+ * ```ts
1468
+ * const scheme = Xcscheme.parse(xcschemeText);
1469
+ * for (const reference of scheme.buildableReferences()) {
1470
+ * reference.blueprintName = "RenamedApp";
1471
+ * reference.buildableName = "RenamedApp.app";
1472
+ * }
1473
+ * const text = scheme.build();
1474
+ * ```
1475
+ */
1476
+ declare class Xcscheme {
1477
+ /** The underlying parsed document. */
1478
+ readonly document: XcschemeDocument;
1479
+ constructor(document: XcschemeDocument);
1480
+ /**
1481
+ * Parses the text of a `.xcscheme` file into a scheme model.
1482
+ *
1483
+ * @throws XcschemeParseError when the text is not a well-formed scheme
1484
+ * document, with the line and column of the failure.
1485
+ */
1486
+ static parse(text: string): Xcscheme;
1487
+ /**
1488
+ * Creates the scheme Xcode writes for an application target. See
1489
+ * {@link createXcscheme} for the shape it produces.
1490
+ */
1491
+ static create(options: CreateXcschemeOptions): Xcscheme;
1492
+ /**
1493
+ * The document's `Scheme` element.
1494
+ */
1495
+ get root(): XcschemeElement;
1496
+ /**
1497
+ * Serializes the scheme to the text of a `.xcscheme` file in Xcode's
1498
+ * canonical layout.
1499
+ */
1500
+ build(): string;
1501
+ /**
1502
+ * Collects elements of the given name anywhere in the document, in
1503
+ * document order. Passing no name collects every element.
1504
+ */
1505
+ elements(name?: string): XcschemeElement[];
1506
+ /**
1507
+ * The views of every buildable reference in the document, in document
1508
+ * order. Build entries, testables, macro expansions, runnables, and
1509
+ * action environment buildables all point at their target through one
1510
+ * of these, so rename flows iterate this list.
1511
+ */
1512
+ buildableReferences(): BuildableReference[];
1513
+ }
1514
+ /**
1515
+ * Options for {@link createXcscheme}.
1516
+ */
1517
+ interface CreateXcschemeOptions {
1518
+ /** The application target's name, which also names the scheme. */
1519
+ appName: string;
1520
+ /**
1521
+ * The `.xcodeproj` directory name the buildable references point at.
1522
+ * Defaults to `<appName>.xcodeproj`.
1523
+ */
1524
+ xcodeprojName?: string;
1525
+ /**
1526
+ * The application target's object id in the project document. Xcode
1527
+ * repairs an empty identifier on first open, so omitting it still
1528
+ * produces a working scheme.
1529
+ */
1530
+ blueprintIdentifier?: string;
1531
+ }
1532
+ /**
1533
+ * Creates the scheme Xcode writes for an application target. The
1534
+ * document carries build, launch, profile, analyze, and archive actions
1535
+ * wired to the app product, with Xcode's default configuration choices
1536
+ * of Debug for development actions and Release for profiling and
1537
+ * archiving.
1538
+ */
1539
+ declare function createXcscheme(options: CreateXcschemeOptions): XcschemeDocument;
1540
+ //#endregion
1541
+ //#region src/scheme/parse.d.ts
1542
+ /**
1543
+ * Parses the text of a `.xcscheme` file into its node tree.
1544
+ *
1545
+ * @throws XcschemeParseError when the text is not a well-formed scheme
1546
+ * document, with the line and column of the failure.
1547
+ */
1548
+ declare function parseXcscheme(text: string): XcschemeDocument;
1549
+ //#endregion
1248
1550
  //#region src/uuid.d.ts
1249
1551
  /**
1250
1552
  * Deterministic object identifiers for generated pbxproj objects.
@@ -1272,4 +1574,4 @@ declare function parsePbxproj(text: string): PbxprojValue;
1272
1574
  */
1273
1575
  declare function generateObjectId(seed: string, existing: ReadonlySet<string>): string;
1274
1576
  //#endregion
1275
- export { type AddNativeTargetOptions, AggregateTarget, type ApplePlatform, type BuildConfigurationProperties, type BuildFileProperties, BuildPhase, type BuildPhaseProperties, BuildRule, type BuildRuleProperties, type BuildSettings, type ConfigurationListProperties, type ContainerItemProxyProperties, CopyFilesDestination, type ExceptionSetProperties, type FileReferenceProperties, Group, type GroupProperties, Isa, LegacyTarget, type LegacyTargetProperties, NativeTarget, type NativeTargetProperties, type PbxprojArray, PbxprojBuildError, type PbxprojErrorPosition, type PbxprojObject, PbxprojParseError, type PbxprojValue, ProductType, type ProjectIssue, type ProjectIssueKind, ReferenceProxy, type ReferenceProxyProperties, RootProject, type RootProjectProperties, type SwiftPackageProductDependencyProperties, type SwiftPackageReferenceProperties, SyncRootGroup, type SyncRootGroupProperties, Target, type TargetDependencyProperties, type TargetProperties, VersionGroup, type VersionGroupProperties, XcodeModelError, XcodeObject, XcodeProject, buildPbxproj, generateObjectId, parsePbxproj };
1577
+ export { type AddNativeTargetOptions, AggregateTarget, type ApplePlatform, BuildConfiguration, type BuildConfigurationProperties, type BuildFileProperties, BuildPhase, type BuildPhaseProperties, BuildRule, type BuildRuleProperties, type BuildSettings, BuildableReference, type ConfigurationListProperties, ContainerItemProxy, type ContainerItemProxyProperties, CopyFilesDestination, type CreateXcschemeOptions, type ExceptionSetProperties, FileReference, type FileReferenceProperties, Group, type GroupProperties, Isa, LegacyTarget, type LegacyTargetProperties, NativeTarget, type NativeTargetProperties, type PbxprojArray, PbxprojBuildError, type PbxprojErrorPosition, type PbxprojObject, PbxprojParseError, type PbxprojValue, ProductType, type ProjectIssue, type ProjectIssueKind, ReferenceProxy, type ReferenceProxyProperties, RootProject, type RootProjectProperties, type SwiftPackageProductDependencyProperties, type SwiftPackageReferenceProperties, SyncRootGroup, type SyncRootGroupProperties, Target, type TargetDependencyProperties, type TargetProperties, VersionGroup, type VersionGroupProperties, XcodeModelError, XcodeObject, XcodeProject, Xcscheme, XcschemeBuildError, type XcschemeComment, type XcschemeDocument, type XcschemeElement, type XcschemeNode, XcschemeParseError, buildPbxproj, buildXcscheme, createXcscheme, generateObjectId, isXcschemeElement, parsePbxproj, parseXcscheme, xcschemeElements };