xcodebuild-axi 0.1.12 → 0.1.14
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/CHANGELOG.md +85 -1
- package/README.md +12 -14
- package/dist/src/commands/build.d.ts +2 -2
- package/dist/src/commands/build.js +143 -4
- package/dist/src/commands/build.js.map +1 -1
- package/dist/src/commands/sim.d.ts +20 -2
- package/dist/src/commands/sim.js +351 -17
- package/dist/src/commands/sim.js.map +1 -1
- package/dist/src/simctl.d.ts +26 -1
- package/dist/src/simctl.js +60 -2
- package/dist/src/simctl.js.map +1 -1
- package/dist/src/surface.js +8 -29
- package/dist/src/surface.js.map +1 -1
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -6,6 +6,88 @@ Notable changes to `xcodebuild-axi`. Versions follow
|
|
|
6
6
|
|
|
7
7
|
## [Unreleased]
|
|
8
8
|
|
|
9
|
+
## [0.1.14] - 2026-09-22
|
|
10
|
+
|
|
11
|
+
### Added
|
|
12
|
+
|
|
13
|
+
- **`sim apps <device> <bundle-id>` reports one app in full**, which is
|
|
14
|
+
`simctl appinfo`. The list stops at the bundle; this adds the data container
|
|
15
|
+
a test writes into, the App Groups it shares, and whether the app is
|
|
16
|
+
first-party, hidden, removable or an app clip. Same subcommand rather than a
|
|
17
|
+
new one, because the list is where you are when you want it.
|
|
18
|
+
|
|
19
|
+
Paths come back out of `appinfo` as `file://` URLs with percent-escapes —
|
|
20
|
+
`iOS%2026.5.simruntime` — and are decoded to something a shell will take.
|
|
21
|
+
The four flags print as `0` and `1` and survive `plutil` as the _strings_
|
|
22
|
+
`"0"` and `"1"`, so all three spellings are read.
|
|
23
|
+
|
|
24
|
+
- **`sim pasteboard <device> [text]` reads and writes the pasteboard.** With
|
|
25
|
+
text it copies, without it pastes. Two simctl subcommands (`pbcopy`,
|
|
26
|
+
`pbpaste`) become one, because they are the same question asked in two
|
|
27
|
+
directions and the separate names only make sense standing in a shell that
|
|
28
|
+
already has both. `pbcopy` takes its input on stdin and nowhere else, so
|
|
29
|
+
`simctl()` grew an optional stdin.
|
|
30
|
+
|
|
31
|
+
### Notes
|
|
32
|
+
|
|
33
|
+
- **`simctl install_app_data` does not work on Xcode 27** and stays declined.
|
|
34
|
+
It was going to be wrapped in this release. Every package shape was tried —
|
|
35
|
+
with and without `AppDataInfo.plist`, with `bundleID` / `CFBundleIdentifier`
|
|
36
|
+
/ `BundleID` as its key, with and without the container's own
|
|
37
|
+
`.com.apple.mobile_container_manager.metadata.plist`, against a first-party
|
|
38
|
+
and a user app, on a booted device and a freshly created one, from `/tmp`
|
|
39
|
+
and from a home directory — and all of them fail the same way:
|
|
40
|
+
`com.apple.containermanager` code 55, "Could not get the existing data
|
|
41
|
+
container location for the app". The one shape that behaves differently is a
|
|
42
|
+
wrong bundle id, which says so. Wrapping a subcommand that cannot succeed
|
|
43
|
+
would be a command that only ever reports someone else's bug.
|
|
44
|
+
|
|
45
|
+
## [0.1.13] - 2026-09-21
|
|
46
|
+
|
|
47
|
+
### Added
|
|
48
|
+
|
|
49
|
+
- **`sim` seeds the fixtures a test needs and says where the app's files
|
|
50
|
+
went.** `location`, `media` and `container`.
|
|
51
|
+
|
|
52
|
+
`sim location "iPhone 17 Pro" 37.7749,-122.4194` puts the device somewhere;
|
|
53
|
+
two or more pairs move it between them (`--speed` sets how fast), a name
|
|
54
|
+
runs one of simctl's own scenarios, and no argument lists them — simctl
|
|
55
|
+
offers no way to read the current location back, so the list is the only
|
|
56
|
+
useful thing a bare call can say. A scenario name is matched
|
|
57
|
+
case-insensitively against that list, because simctl's own answer to a near
|
|
58
|
+
miss is "Could not find scenario".
|
|
59
|
+
|
|
60
|
+
`sim media "iPhone 17 Pro" receipt.png` adds photos, live photos, videos and
|
|
61
|
+
vCard contacts to the library. A file that is not there is refused before
|
|
62
|
+
simctl is called; a file it refuses comes back as
|
|
63
|
+
`receipt.heic — File type unsupported` rather than as the two-paragraph
|
|
64
|
+
"Multiple errors were returned; see stderr" simctl prints.
|
|
65
|
+
|
|
66
|
+
`sim container "iPhone 17 Pro"` answers where the app's files are with both
|
|
67
|
+
paths at once — the installed bundle and the data directory a test writes
|
|
68
|
+
into — because asking for one and then needing the other is two calls.
|
|
69
|
+
`groups` lists the App Group containers, and any `group.` identifier works
|
|
70
|
+
as well.
|
|
71
|
+
|
|
72
|
+
- **`build --install-src` copies a project's sources out.** The last
|
|
73
|
+
xcodebuild action left, which takes the headline number to **100% of the 161
|
|
74
|
+
leaves `xcodebuild -help` documents**.
|
|
75
|
+
|
|
76
|
+
It was declined for a while because it writes outside
|
|
77
|
+
`~/Library/Caches/xcodebuild-axi`, which nothing else here does. So it
|
|
78
|
+
doesn't: the copy lands in this project's cache directory, and `--src-root`
|
|
79
|
+
puts it somewhere else only with `--yes`, the way `migrate --format` works.
|
|
80
|
+
A destination that already exists is refused rather than emptied — deleting
|
|
81
|
+
a directory the caller named is not this tool's call.
|
|
82
|
+
|
|
83
|
+
Three things about `installsrc` that its own help does not say, all verified
|
|
84
|
+
against a real project: it **cannot run against a workspace** (it rejects
|
|
85
|
+
`-scheme`, and a workspace refuses to act without one — so the `.xcodeproj`
|
|
86
|
+
beside the workspace is used), it **refuses a destination that exists**, and
|
|
87
|
+
it **copies the whole project directory**, DerivedData included. A 271 MB
|
|
88
|
+
checkout came out as 258 MB across 5,104 files. The report says so, because
|
|
89
|
+
"installsrc" reads like a source export and is a packaging step.
|
|
90
|
+
|
|
9
91
|
## [0.1.12] - 2026-09-21
|
|
10
92
|
|
|
11
93
|
### Added
|
|
@@ -525,7 +607,9 @@ First release.
|
|
|
525
607
|
- 100% of the 117 options `xcodebuild -help` lists are covered, declared in
|
|
526
608
|
`src/surface.ts` and checked against the installed Xcode in CI.
|
|
527
609
|
|
|
528
|
-
[unreleased]: https://github.com/alexrrouse/xcodebuild-axi/compare/v0.1.
|
|
610
|
+
[unreleased]: https://github.com/alexrrouse/xcodebuild-axi/compare/v0.1.14...HEAD
|
|
611
|
+
[0.1.14]: https://github.com/alexrrouse/xcodebuild-axi/compare/v0.1.13...v0.1.14
|
|
612
|
+
[0.1.13]: https://github.com/alexrrouse/xcodebuild-axi/compare/v0.1.12...v0.1.13
|
|
529
613
|
[0.1.12]: https://github.com/alexrrouse/xcodebuild-axi/compare/v0.1.11...v0.1.12
|
|
530
614
|
[0.1.11]: https://github.com/alexrrouse/xcodebuild-axi/compare/v0.1.10...v0.1.11
|
|
531
615
|
[0.1.10]: https://github.com/alexrrouse/xcodebuild-axi/compare/v0.1.9...v0.1.10
|
package/README.md
CHANGED
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
<a href="https://www.npmjs.com/package/xcodebuild-axi"><img alt="npm" src="https://img.shields.io/npm/v/xcodebuild-axi?style=flat-square" /></a>
|
|
5
5
|
<a href="https://axi.md/"><img alt="AXI" src="https://img.shields.io/badge/AXI-compliant-blue?style=flat-square" /></a>
|
|
6
6
|
<img alt="Platform" src="https://img.shields.io/badge/platform-macOS-lightgrey?style=flat-square" />
|
|
7
|
-
<!-- coverage-badge:start --><img alt="xcodebuild coverage" src="https://img.shields.io/badge/xcodebuild_coverage-
|
|
7
|
+
<!-- coverage-badge:start --><img alt="xcodebuild coverage" src="https://img.shields.io/badge/xcodebuild_coverage-100%25-brightgreen?style=flat-square" /><!-- coverage-badge:end -->
|
|
8
8
|
<img alt="License" src="https://img.shields.io/badge/license-MIT-green?style=flat-square" />
|
|
9
9
|
</p>
|
|
10
10
|
|
|
@@ -171,18 +171,18 @@ Every command takes `--help`.
|
|
|
171
171
|
|
|
172
172
|
<!-- coverage:start -->
|
|
173
173
|
|
|
174
|
-
**Coverage:
|
|
174
|
+
**Coverage: 100% of the 161 leaves `xcodebuild` documents** — every option, build action, export options key, `-create-xcframework` argument, and the second forms that only a usage line mentions.
|
|
175
175
|
|
|
176
176
|
A leaf is one switch you could type. Counting options alone says 100% (117/117), which was true and hid every gap below: an option is one thing, and `-exportOptionsPlist` alone opens eighteen more.
|
|
177
177
|
|
|
178
|
-
| Surface | Leaves | Covered
|
|
179
|
-
| ------------------------------------------------------ | ------- |
|
|
180
|
-
| `xcodebuild -help` options | 117 | 117 (100%)
|
|
181
|
-
| build actions | 10 |
|
|
182
|
-
| second forms (`-version <infoitem>`, `-license check`) | 8 | 8 (100%)
|
|
183
|
-
| `-exportOptionsPlist` keys | 18 | 18 (100%)
|
|
184
|
-
| `-create-xcframework` options | 8 | 8 (100%)
|
|
185
|
-
| **total** | **161** | **
|
|
178
|
+
| Surface | Leaves | Covered |
|
|
179
|
+
| ------------------------------------------------------ | ------- | -------------- |
|
|
180
|
+
| `xcodebuild -help` options | 117 | 117 (100%) |
|
|
181
|
+
| build actions | 10 | 10 (100%) |
|
|
182
|
+
| second forms (`-version <infoitem>`, `-license check`) | 8 | 8 (100%) |
|
|
183
|
+
| `-exportOptionsPlist` keys | 18 | 18 (100%) |
|
|
184
|
+
| `-create-xcframework` options | 8 | 8 (100%) |
|
|
185
|
+
| **total** | **161** | **161 (100%)** |
|
|
186
186
|
|
|
187
187
|
**Reach: 100%** of the 328 command-and-option pairs. The same options, counted once per command xcodebuild accepts them on — because `-target` exposed on `build` and missing from `settings` is not covered for anyone asking `settings`. 0 pairs are open.
|
|
188
188
|
|
|
@@ -200,17 +200,15 @@ A leaf is one switch you could type. Counting options alone says 100% (117/117),
|
|
|
200
200
|
| `-help` | `xcodebuild-axi --help`, which answers it in a fraction of the tokens |
|
|
201
201
|
| `-usage` | `xcodebuild-axi <command> --help`, per command rather than all 117 at once |
|
|
202
202
|
|
|
203
|
-
The one action left out is `installsrc` — it copies sources into `SRCROOT` as root, which is a packaging step rather than anything an agent loop needs.
|
|
204
|
-
|
|
205
203
|
### Companion tools
|
|
206
204
|
|
|
207
|
-
`xcresulttool`, `xccov` and `simctl` are not xcodebuild, so they are not in the number above — but this tool wraps all three, and an agent that has to shell out to one directly has dropped back down. **
|
|
205
|
+
`xcresulttool`, `xccov` and `simctl` are not xcodebuild, so they are not in the number above — but this tool wraps all three, and an agent that has to shell out to one directly has dropped back down. **70.4% of 71 leaves**, counted the same way:
|
|
208
206
|
|
|
209
207
|
| Tool | Leaves | Covered |
|
|
210
208
|
| -------------- | ------ | ---------- |
|
|
211
209
|
| `xcresulttool` | 21 | 17 (81%) |
|
|
212
210
|
| `xccov` | 9 | 9 (100%) |
|
|
213
|
-
| `simctl` | 41 |
|
|
211
|
+
| `simctl` | 41 | 24 (58.5%) |
|
|
214
212
|
|
|
215
213
|
The denominator is read from `xcodebuild -help` rather than hand-maintained, and this table is written against **Xcode 27.0** — the option list moves between releases. `npm run coverage:check` fails on that Xcode if an option here is unclassified or has been dropped, and reports the difference without failing on any other.
|
|
216
214
|
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
export declare const BUILD_HELP = "usage: xcodebuild-axi build [flags]\nBuilds a scheme and reports only what failed, with exact source locations.\nflags[
|
|
2
|
-
export declare const BUILD_FLAGS: readonly ["--scheme", "--target", "--all-targets", "--device", "--destination", "--configuration", "--sdk", "--arch", "--toolchain", "--xcconfig", "--derived-data", "--artifacts-dir", "--jobs", "--setting", "--sign", "--allow-provisioning", "--sanitizer", "--timing", "--destination-timeout", "--parallelize-targets", "--hide-script-env", "--skip-unavailable-actions", "--max-errors", "--full", "--codesize", "--log-level", "--bundle-version", "--stream", "--offline", "--cache", "--package-cache", "--no-auto-resolve", "--skip-package-updates", "--no-package-cache", "--skip-plugin-validation", "--skip-signature-validation", "--package-auth", "--registry-url", "--scm-to-registry", "--fingerprint-policy", "--signing-entity-policy", "--scm-provider", "--clean", "--for-testing", "--install", "--docs"];
|
|
1
|
+
export declare const BUILD_HELP = "usage: xcodebuild-axi build [flags]\nBuilds a scheme and reports only what failed, with exact source locations.\nflags[49]:\n --scheme <name> scheme to act on (required only when the project has more than one)\n --target <name> build a target instead of a scheme; repeatable (project only)\n --all-targets build every target in the project (project only)\n --device <name> simulator or device name, e.g. \"iPhone 17 Pro\" (default: newest simulator)\n --destination <spec> raw xcodebuild destination specifier, passed through untouched\n --configuration <name> build configuration (default: the scheme's own)\n --sdk <name> base SDK, e.g. iphonesimulator\n --arch <arch> architecture to build; repeatable or comma-separated\n --toolchain <name> toolchain identifier or name\n --xcconfig <path> apply build settings from this file as overrides\n --derived-data <path> derived data directory\n --artifacts-dir <path> where to write this run's log and .xcresult (default: the tool's cache)\n --jobs <n> maximum concurrent build operations\n --setting KEY=VALUE build setting override; repeatable or comma-separated\n --sign allow code signing (off by default, so simulator builds need no team)\n --allow-provisioning let xcodebuild talk to the developer portal for profiles\n --sanitizer <name> address, thread, or undefined; repeatable or comma-separated\n --timing report per-command build timings\n --destination-timeout <secs> how long to wait for the destination device\n --parallelize-targets build independent targets in parallel\n --hide-script-env omit shell script environment variables from the log\n --skip-unavailable-actions skip scheme actions that cannot run instead of failing\n --max-errors <n> errors to list before summarizing the rest (default: 20)\n --full list every warning instead of the first 10\n --codesize <dir> write a code size profile to this directory\n --log-level <level> quiet, normal, or verbose \u2014 how much lands in the log file\n --bundle-version <n> result bundle format version (default: xcodebuild's own)\n --stream <path> also write xcodebuild's live result stream here\n --offline resolve using only the versions already in Package.resolved\n --cache <path> clone remote packages into this directory\n --package-cache <path> shared package cache directory (across projects)\n --no-auto-resolve never resolve automatically; fail if Package.resolved is stale\n --skip-package-updates use the packages already cloned, without checking for updates\n --no-package-cache ignore the shared package repository cache\n --skip-plugin-validation trust build plugins without prompting\n --skip-signature-validation do not verify package signatures\n --package-auth <kind> keychain or netrc\n --registry-url <url> default package registry\n --scm-to-registry <kind> none, identity, or swift-package-registry\n --fingerprint-policy <kind> strict or warn\n --signing-entity-policy <kind> strict or warn\n --scm-provider <kind> system or xcode\n --clean clean before building\n --for-testing build the tests too and emit an .xctestrun (build-for-testing)\n --install run the install action instead of build\n --docs build documentation (docbuild) instead of build\n --install-src copy the project's sources out instead of building (installsrc)\n --src-root <path> with --install-src: where to copy them; needs --yes\n --yes required to copy sources anywhere but the cache\nexit:\n 0 build succeeded, 1 build failed, 2 usage error\nexamples:\n xcodebuild-axi build\n xcodebuild-axi build --scheme MyApp --device \"iPhone 17 Pro\"\n xcodebuild-axi build --scheme MyApp --configuration Release --clean\n xcodebuild-axi build --scheme MyApp --for-testing\n xcodebuild-axi build --install-src\n";
|
|
2
|
+
export declare const BUILD_FLAGS: readonly ["--scheme", "--target", "--all-targets", "--device", "--destination", "--configuration", "--sdk", "--arch", "--toolchain", "--xcconfig", "--derived-data", "--artifacts-dir", "--jobs", "--setting", "--sign", "--allow-provisioning", "--sanitizer", "--timing", "--destination-timeout", "--parallelize-targets", "--hide-script-env", "--skip-unavailable-actions", "--max-errors", "--full", "--codesize", "--log-level", "--bundle-version", "--stream", "--offline", "--cache", "--package-cache", "--no-auto-resolve", "--skip-package-updates", "--no-package-cache", "--skip-plugin-validation", "--skip-signature-validation", "--package-auth", "--registry-url", "--scm-to-registry", "--fingerprint-policy", "--signing-entity-policy", "--scm-provider", "--clean", "--for-testing", "--install", "--docs", "--install-src", "--src-root", "--yes"];
|
|
3
3
|
export declare function buildCommand(args: string[]): Promise<string>;
|
|
@@ -1,14 +1,22 @@
|
|
|
1
1
|
import { BUILD_FLAG_HELP, reportAction, resolveBuildContext, runAction, SHARED_BUILD_FLAGS, SHARED_BUILD_VALUE_FLAGS, } from "../action.js";
|
|
2
|
-
import { AxiError } from "../errors.js";
|
|
3
|
-
import { hasFlag, rejectUnknownFlags } from "../args.js";
|
|
2
|
+
import { AxiError, mapXcodebuildError } from "../errors.js";
|
|
3
|
+
import { getFlag, hasFlag, rejectUnknownFlags } from "../args.js";
|
|
4
|
+
import { existsSync, readdirSync, rmSync, statSync } from "node:fs";
|
|
5
|
+
import { basename, join, resolve as resolvePath } from "node:path";
|
|
6
|
+
import { requireProject } from "../context.js";
|
|
7
|
+
import { artifactDir, runBuild } from "../xcodebuild.js";
|
|
8
|
+
import { byteSize, duration, renderFields, renderHelp, renderOutput, tildePath, } from "../toon.js";
|
|
4
9
|
export const BUILD_HELP = `usage: xcodebuild-axi build [flags]
|
|
5
10
|
Builds a scheme and reports only what failed, with exact source locations.
|
|
6
|
-
flags[
|
|
11
|
+
flags[49]:
|
|
7
12
|
${BUILD_FLAG_HELP}
|
|
8
13
|
--clean clean before building
|
|
9
14
|
--for-testing build the tests too and emit an .xctestrun (build-for-testing)
|
|
10
15
|
--install run the install action instead of build
|
|
11
16
|
--docs build documentation (docbuild) instead of build
|
|
17
|
+
--install-src copy the project's sources out instead of building (installsrc)
|
|
18
|
+
--src-root <path> with --install-src: where to copy them; needs --yes
|
|
19
|
+
--yes required to copy sources anywhere but the cache
|
|
12
20
|
exit:
|
|
13
21
|
0 build succeeded, 1 build failed, 2 usage error
|
|
14
22
|
examples:
|
|
@@ -16,6 +24,7 @@ examples:
|
|
|
16
24
|
xcodebuild-axi build --scheme MyApp --device "iPhone 17 Pro"
|
|
17
25
|
xcodebuild-axi build --scheme MyApp --configuration Release --clean
|
|
18
26
|
xcodebuild-axi build --scheme MyApp --for-testing
|
|
27
|
+
xcodebuild-axi build --install-src
|
|
19
28
|
`;
|
|
20
29
|
export const BUILD_FLAGS = [
|
|
21
30
|
...SHARED_BUILD_FLAGS,
|
|
@@ -23,9 +32,15 @@ export const BUILD_FLAGS = [
|
|
|
23
32
|
"--for-testing",
|
|
24
33
|
"--install",
|
|
25
34
|
"--docs",
|
|
35
|
+
"--install-src",
|
|
36
|
+
"--src-root",
|
|
37
|
+
"--yes",
|
|
26
38
|
];
|
|
39
|
+
const BUILD_VALUE_FLAGS = [...SHARED_BUILD_VALUE_FLAGS, "--src-root"];
|
|
27
40
|
export async function buildCommand(args) {
|
|
28
|
-
rejectUnknownFlags(args, "build", BUILD_FLAGS,
|
|
41
|
+
rejectUnknownFlags(args, "build", BUILD_FLAGS, BUILD_VALUE_FLAGS);
|
|
42
|
+
if (hasFlag(args, "--install-src"))
|
|
43
|
+
return installSources(args);
|
|
29
44
|
const action = pickAction(args);
|
|
30
45
|
const context = await resolveBuildContext({ args, command: "build" });
|
|
31
46
|
const run = await runAction({
|
|
@@ -57,4 +72,128 @@ function pickAction(args) {
|
|
|
57
72
|
}
|
|
58
73
|
return chosen[0] ?? "build";
|
|
59
74
|
}
|
|
75
|
+
/**
|
|
76
|
+
* `installsrc`, xcodebuild's own source-copy action.
|
|
77
|
+
*
|
|
78
|
+
* Three things about it are worth knowing before reading this, all verified
|
|
79
|
+
* against a real project:
|
|
80
|
+
*
|
|
81
|
+
* - **It cannot run against a workspace.** `-scheme` is rejected outright
|
|
82
|
+
* ("Cannot use the installsrc action with -scheme") and a workspace refuses
|
|
83
|
+
* to do anything without one, so the only form that works is `-project`.
|
|
84
|
+
* - **It refuses a destination that already exists**, with "Cannot determine
|
|
85
|
+
* install sources to path", the same shape as its refusal to overwrite a
|
|
86
|
+
* result bundle.
|
|
87
|
+
* - **It copies the whole project directory**, build products included — a
|
|
88
|
+
* 271 MB checkout came out as 270 MB, of which most was DerivedData. It is
|
|
89
|
+
* a packaging step rather than a source export, and the report says so.
|
|
90
|
+
*
|
|
91
|
+
* The default destination is this project's cache directory, because
|
|
92
|
+
* everything else here writes only there. A caller who wants it somewhere
|
|
93
|
+
* else says where and confirms, the way `migrate --format` does.
|
|
94
|
+
*/
|
|
95
|
+
async function installSources(args) {
|
|
96
|
+
const conflict = ["--for-testing", "--install", "--docs", "--clean"].find((flag) => hasFlag(args, flag));
|
|
97
|
+
if (conflict !== undefined) {
|
|
98
|
+
throw new AxiError(`Copying sources is not a build and cannot be combined with ${conflict}`, "VALIDATION_ERROR", ["Run the two as separate commands"]);
|
|
99
|
+
}
|
|
100
|
+
const project = requireProject();
|
|
101
|
+
const container = installSrcContainer(project);
|
|
102
|
+
const destination = sourceDestination(args, project);
|
|
103
|
+
const run = await runBuild({
|
|
104
|
+
args: ["-project", container, "installsrc", `SRCROOT=${destination}`],
|
|
105
|
+
label: `${project.name}-installsrc`,
|
|
106
|
+
project,
|
|
107
|
+
});
|
|
108
|
+
if (run.exitCode !== 0) {
|
|
109
|
+
const mapped = mapXcodebuildError(run.tail);
|
|
110
|
+
throw new AxiError(mapped?.message ?? `Could not copy the sources of ${project.name}`, mapped?.code ?? "UNKNOWN", [
|
|
111
|
+
...(mapped?.suggestions ?? []),
|
|
112
|
+
`full transcript: ${tildePath(run.logPath)}`,
|
|
113
|
+
]);
|
|
114
|
+
}
|
|
115
|
+
const { files, bytes } = measure(destination);
|
|
116
|
+
return renderOutput([
|
|
117
|
+
renderFields({
|
|
118
|
+
installsrc: "copied",
|
|
119
|
+
project: project.name,
|
|
120
|
+
files,
|
|
121
|
+
size: byteSize(bytes),
|
|
122
|
+
to: tildePath(destination),
|
|
123
|
+
duration: duration(run.seconds),
|
|
124
|
+
}),
|
|
125
|
+
renderHelp([
|
|
126
|
+
"installsrc copies the whole project directory, build products included — it is xcodebuild's packaging step rather than a source export",
|
|
127
|
+
]),
|
|
128
|
+
]);
|
|
129
|
+
}
|
|
130
|
+
/** The `.xcodeproj` installsrc needs, which is not always what we build with. */
|
|
131
|
+
function installSrcContainer(project) {
|
|
132
|
+
if (project.kind === "project")
|
|
133
|
+
return project.path;
|
|
134
|
+
if (project.kind === "package") {
|
|
135
|
+
throw new AxiError("installsrc needs an Xcode project and a Swift package has none", "VALIDATION_ERROR", [
|
|
136
|
+
"`git archive HEAD` copies a package's sources and leaves the build products behind",
|
|
137
|
+
]);
|
|
138
|
+
}
|
|
139
|
+
// A workspace is a dead end for this action, not a harder case: it demands
|
|
140
|
+
// a scheme and installsrc rejects one. The .xcodeproj beside it is the
|
|
141
|
+
// thing xcodebuild would have picked with no workspace present.
|
|
142
|
+
const dir = resolvePath(project.path, "..");
|
|
143
|
+
const sibling = readdirSync(dir).filter((entry) => entry.endsWith(".xcodeproj"));
|
|
144
|
+
const only = sibling[0];
|
|
145
|
+
if (sibling.length !== 1 || only === undefined) {
|
|
146
|
+
throw new AxiError(`installsrc cannot run against ${basename(project.path)}`, "VALIDATION_ERROR", [
|
|
147
|
+
"xcodebuild rejects `-scheme` with installsrc, and a workspace will not act without one",
|
|
148
|
+
sibling.length === 0
|
|
149
|
+
? "cd to a directory holding a single .xcodeproj, then re-run"
|
|
150
|
+
: `${sibling.length} projects sit beside it: ${sibling.join(", ")}`,
|
|
151
|
+
]);
|
|
152
|
+
}
|
|
153
|
+
return join(dir, only);
|
|
154
|
+
}
|
|
155
|
+
/** Where the copy lands: this project's cache, or a path the caller stands behind. */
|
|
156
|
+
function sourceDestination(args, project) {
|
|
157
|
+
const requested = getFlag(args, "--src-root");
|
|
158
|
+
if (requested === undefined) {
|
|
159
|
+
const cached = join(artifactDir(project), "src");
|
|
160
|
+
// Ours to clear, the way the result bundle is: installsrc will not write
|
|
161
|
+
// into a directory that already exists.
|
|
162
|
+
rmSync(cached, { recursive: true, force: true });
|
|
163
|
+
return cached;
|
|
164
|
+
}
|
|
165
|
+
if (!hasFlag(args, "--yes")) {
|
|
166
|
+
throw new AxiError(`Copying ${project.name} outside the tool's cache needs --yes as well as --src-root`, "VALIDATION_ERROR", [
|
|
167
|
+
`xcodebuild-axi build --install-src --src-root ${requested} --yes`,
|
|
168
|
+
"Without --src-root the copy lands in ~/Library/Caches/xcodebuild-axi",
|
|
169
|
+
]);
|
|
170
|
+
}
|
|
171
|
+
const path = resolvePath(requested);
|
|
172
|
+
if (existsSync(path)) {
|
|
173
|
+
throw new AxiError(`Something is already at ${tildePath(path)}`, "VALIDATION_ERROR", [
|
|
174
|
+
"installsrc refuses a destination that exists, and deleting one you named is not this tool's call",
|
|
175
|
+
"Pass an empty path, or remove it yourself first",
|
|
176
|
+
]);
|
|
177
|
+
}
|
|
178
|
+
return path;
|
|
179
|
+
}
|
|
180
|
+
/** What actually landed, since installsrc reports only that it started. */
|
|
181
|
+
function measure(dir) {
|
|
182
|
+
let files = 0;
|
|
183
|
+
let bytes = 0;
|
|
184
|
+
const walk = (path) => {
|
|
185
|
+
for (const entry of readdirSync(path, { withFileTypes: true })) {
|
|
186
|
+
const child = join(path, entry.name);
|
|
187
|
+
if (entry.isDirectory()) {
|
|
188
|
+
walk(child);
|
|
189
|
+
}
|
|
190
|
+
else if (entry.isFile()) {
|
|
191
|
+
files += 1;
|
|
192
|
+
bytes += statSync(child).size;
|
|
193
|
+
}
|
|
194
|
+
}
|
|
195
|
+
};
|
|
196
|
+
walk(dir);
|
|
197
|
+
return { files, bytes };
|
|
198
|
+
}
|
|
60
199
|
//# sourceMappingURL=build.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"build.js","sourceRoot":"","sources":["../../../src/commands/build.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,eAAe,EACf,YAAY,EACZ,mBAAmB,EACnB,SAAS,EACT,kBAAkB,EAClB,wBAAwB,GACzB,MAAM,cAAc,CAAC;AACtB,OAAO,EAAE,QAAQ,EAAE,MAAM,cAAc,CAAC;
|
|
1
|
+
{"version":3,"file":"build.js","sourceRoot":"","sources":["../../../src/commands/build.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,eAAe,EACf,YAAY,EACZ,mBAAmB,EACnB,SAAS,EACT,kBAAkB,EAClB,wBAAwB,GACzB,MAAM,cAAc,CAAC;AACtB,OAAO,EAAE,QAAQ,EAAE,kBAAkB,EAAE,MAAM,cAAc,CAAC;AAC5D,OAAO,EAAE,OAAO,EAAE,OAAO,EAAE,kBAAkB,EAAE,MAAM,YAAY,CAAC;AAClE,OAAO,EAAE,UAAU,EAAE,WAAW,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,SAAS,CAAC;AACpE,OAAO,EAAE,QAAQ,EAAE,IAAI,EAAE,OAAO,IAAI,WAAW,EAAE,MAAM,WAAW,CAAC;AACnE,OAAO,EAAE,cAAc,EAAE,MAAM,eAAe,CAAC;AAE/C,OAAO,EAAE,WAAW,EAAE,QAAQ,EAAE,MAAM,kBAAkB,CAAC;AACzD,OAAO,EACL,QAAQ,EACR,QAAQ,EACR,YAAY,EACZ,UAAU,EACV,YAAY,EACZ,SAAS,GACV,MAAM,YAAY,CAAC;AAEpB,MAAM,CAAC,MAAM,UAAU,GAAG;;;EAGxB,eAAe;;;;;;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kBAAkB,EAClB;YACE,iDAAiD,SAAS,QAAQ;YAClE,sEAAsE;SACvE,CACF,CAAC;IACJ,CAAC;IAED,MAAM,IAAI,GAAG,WAAW,CAAC,SAAS,CAAC,CAAC;IACpC,IAAI,UAAU,CAAC,IAAI,CAAC,EAAE,CAAC;QACrB,MAAM,IAAI,QAAQ,CAChB,2BAA2B,SAAS,CAAC,IAAI,CAAC,EAAE,EAC5C,kBAAkB,EAClB;YACE,kGAAkG;YAClG,iDAAiD;SAClD,CACF,CAAC;IACJ,CAAC;IACD,OAAO,IAAI,CAAC;AACd,CAAC;AAED,2EAA2E;AAC3E,SAAS,OAAO,CAAC,GAAW;IAC1B,IAAI,KAAK,GAAG,CAAC,CAAC;IACd,IAAI,KAAK,GAAG,CAAC,CAAC;IACd,MAAM,IAAI,GAAG,CAAC,IAAY,EAAQ,EAAE;QAClC,KAAK,MAAM,KAAK,IAAI,WAAW,CAAC,IAAI,EAAE,EAAE,aAAa,EAAE,IAAI,EAAE,CAAC,EAAE,CAAC;YAC/D,MAAM,KAAK,GAAG,IAAI,CAAC,IAAI,EAAE,KAAK,CAAC,IAAI,CAAC,CAAC;YACrC,IAAI,KAAK,CAAC,WAAW,EAAE,EAAE,CAAC;gBACxB,IAAI,CAAC,KAAK,CAAC,CAAC;YACd,CAAC;iBAAM,IAAI,KAAK,CAAC,MAAM,EAAE,EAAE,CAAC;gBAC1B,KAAK,IAAI,CAAC,CAAC;gBACX,KAAK,IAAI,QAAQ,CAAC,KAAK,CAAC,CAAC,IAAI,CAAC;YAChC,CAAC;QACH,CAAC;IACH,CAAC,CAAC;IACF,IAAI,CAAC,GAAG,CAAC,CAAC;IACV,OAAO,EAAE,KAAK,EAAE,KAAK,EAAE,CAAC;AAC1B,CAAC"}
|
|
@@ -1,8 +1,26 @@
|
|
|
1
1
|
import { type InstalledApp } from "../simctl.js";
|
|
2
|
-
export declare const SIM_HELP = "usage: xcodebuild-axi sim [subcommand] [name|udid] [app] [flags]\nInspects and drives simulators. With no subcommand, lists the booted ones.\nsubcommands[
|
|
3
|
-
export declare const SIM_FLAGS: readonly ["--runtime", "--booted", "--all", "--system", "--scheme", "--relaunch", "--unavailable", "--seconds", "--yes", "--message", "--title", "--time", "--battery", "--bars"];
|
|
2
|
+
export declare const SIM_HELP = "usage: xcodebuild-axi sim [subcommand] [name|udid] [app] [flags]\nInspects and drives simulators. With no subcommand, lists the booted ones.\nsubcommands[22]:\n list every available simulator\n boot <name|udid> boot one, or no-op if it is already booted\n shutdown <name|udid> shut one down, or no-op if it already is; --all for every booted one\n erase <name|udid> erase one back to factory state; --all for every shut-down one\n apps <name|udid> [bundle-id] the apps installed on it, or one in full;\n --system to include Apple's\n install <name|udid> [path.app] install an app; without a path, the one\n this project builds for that simulator\n launch <name|udid> [bundle-id] launch it; without an id, this project's\n terminate <name|udid> [bundle-id] stop it, or no-op if it is not running\n uninstall <name|udid> [bundle-id] remove it\n create <name> <model> create a device; --runtime picks the OS\n delete <name|udid> delete one; --unavailable for every orphaned device\n screenshot <name|udid> [path] save a PNG of its screen\n video <name|udid> [path] record its screen; --seconds sets how long\n open <name|udid> <url> open a URL on it, deep links included\n privacy <name|udid> <grant|revoke|reset> <service> [bundle-id]\n answer a permission prompt before it appears\n push <name|udid> [bundle-id] [payload.json]\n send a push; --message writes the payload for you\n status-bar <name|udid> [pin|clear] freeze the status bar for a screenshot\n ui <name|udid> [light|dark|<setting> <value>] read or set appearance,\n contrast and content size\n location <name|udid> [lat,lon|scenario|clear] put the device somewhere;\n two or more pairs move it between them\n media <name|udid> <path> [...] add photos, videos or contacts to it\n container <name|udid> [bundle-id] [app|data|groups]\n where an app's files are on this machine\n pasteboard <name|udid> [text] read what is on its pasteboard, or put\n something there\nflags[15]:\n --runtime <name> filter the list, e.g. \"iOS 26.5\"\n --booted list only booted simulators\n --all apply shutdown or erase to every eligible simulator\n --system include Apple's own apps in `apps`\n --scheme <name> which scheme's app to install or launch\n --relaunch with launch: stop a running copy first\n --unavailable with delete: every device whose runtime is gone\n --seconds <n> with video: how long to record (default: 10)\n --yes required to delete every simulator at once\n --message <text> with push: the alert body to send\n --title <text> with push: the alert title\n --time <string> with status-bar: the clock, e.g. \"9:41\"\n --battery <0-100> with status-bar: the battery level\n --bars <0-4> with status-bar: wifi and cellular signal strength\n --speed <m/s> with location: how fast to move between waypoints\nnote:\n install, launch, terminate and uninstall take the app as a path or a bundle\n id, and work it out from the project in the current directory when it is\n left off \u2014 the point of them is the loop from a build to a running app, and\n a DerivedData path is not something worth typing.\nexamples:\n xcodebuild-axi sim\n xcodebuild-axi sim list --runtime \"iOS 26.5\"\n xcodebuild-axi sim boot \"iPhone 17 Pro\"\n xcodebuild-axi sim install \"iPhone 17 Pro\"\n xcodebuild-axi sim launch \"iPhone 17 Pro\" --relaunch\n xcodebuild-axi sim apps \"iPhone 17 Pro\"\n xcodebuild-axi sim screenshot \"iPhone 17 Pro\"\n xcodebuild-axi sim create \"Test iPhone\" \"iPhone 17 Pro\" --runtime \"iOS 26.5\"\n xcodebuild-axi sim open \"iPhone 17 Pro\" myapp://checkout\n xcodebuild-axi sim privacy \"iPhone 17 Pro\" grant photos\n xcodebuild-axi sim status-bar \"iPhone 17 Pro\" pin\n xcodebuild-axi sim ui \"iPhone 17 Pro\" dark\n xcodebuild-axi sim location \"iPhone 17 Pro\" 37.7749,-122.4194\n xcodebuild-axi sim media \"iPhone 17 Pro\" fixtures/receipt.png\n xcodebuild-axi sim container \"iPhone 17 Pro\" data\n xcodebuild-axi sim pasteboard \"iPhone 17 Pro\" \"MyApp-1a2b3c4d\"\n";
|
|
3
|
+
export declare const SIM_FLAGS: readonly ["--runtime", "--booted", "--all", "--system", "--scheme", "--relaunch", "--unavailable", "--seconds", "--yes", "--message", "--title", "--time", "--battery", "--bars", "--speed"];
|
|
4
4
|
export declare function simCommand(args: string[]): Promise<string>;
|
|
5
5
|
export declare function appRow(app: InstalledApp): Record<string, unknown>;
|
|
6
|
+
/**
|
|
7
|
+
* Version and build as one field: TOON quotes `"1.0"` and `"1"` because they
|
|
8
|
+
* look like numbers, and two quoted columns cost more than the one readable
|
|
9
|
+
* string they add up to.
|
|
10
|
+
*/
|
|
11
|
+
export declare function versionOf(app: Pick<InstalledApp, "version" | "build">): string;
|
|
12
|
+
/**
|
|
13
|
+
* simctl prints its scenarios as a two-column table with the name repeated as
|
|
14
|
+
* the description, under a header and a row of equals signs.
|
|
15
|
+
*/
|
|
16
|
+
export declare function scenarioNames(stdout: string): string[];
|
|
17
|
+
/**
|
|
18
|
+
* simctl reports a rejected file as
|
|
19
|
+
* `Failed to import '<path>', error [<domain>] 22: ... File type unsupported.`
|
|
20
|
+
* and then says "see stderr", which is where the reader already is. The
|
|
21
|
+
* useful half is the filename and the last sentence.
|
|
22
|
+
*/
|
|
23
|
+
export declare function importComplaints(stderr: string): string[];
|
|
6
24
|
/** A payload is the argument with a path in it; a bundle id is the other one. */
|
|
7
25
|
export declare function isPayloadPath(value: string): boolean;
|
|
8
26
|
/**
|