@absolutejs/absolute 0.20.0-beta.50 → 0.20.0-beta.51
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/dist/angular/components/core/streamingSlotRegistrar.js +1 -1
- package/dist/angular/components/core/streamingSlotRegistry.js +2 -2
- package/dist/cli/index.js +327 -36
- package/dist/mobile/index.js +301 -30
- package/dist/mobile/index.js.map +5 -5
- package/dist/mobile/remoteMacAgentEntry.js +361 -190
- package/dist/src/mobile/iosRelease.d.ts +47 -0
- package/dist/src/mobile/remoteMacProtocol.d.ts +52 -0
- package/dist/src/mobile/remoteMacWire.d.ts +1 -1
- package/package.json +1 -1
package/dist/mobile/index.js
CHANGED
|
@@ -2706,6 +2706,27 @@ var requireBuildNumber = (value) => {
|
|
|
2706
2706
|
throw new TypeError("iOS build number must be a positive integer.");
|
|
2707
2707
|
return value;
|
|
2708
2708
|
};
|
|
2709
|
+
var requireAbsoluteIosReleaseMetadata = (value) => {
|
|
2710
|
+
if (!isRecord2(value) || value.artifact !== "App.ipa" || typeof value.appBuild !== "string" || typeof value.appId !== "string" || typeof value.bytes !== "number" || !Number.isSafeInteger(value.bytes) || value.bytes < 1 || value.engine !== "capacitor" && value.engine !== "expo" || value.format !== ABSOLUTE_IOS_RELEASE_FORMAT || typeof value.marketingVersion !== "string" || value.platform !== "ios" || typeof value.releaseId !== "string" || typeof value.runtime !== "string" || typeof value.sha256 !== "string" || typeof value.signed !== "boolean" || value.type !== "ipa" || value.buildNumber !== undefined && (typeof value.buildNumber !== "number" || !Number.isSafeInteger(value.buildNumber) || value.buildNumber < 1) || !/^amobile_ios_[a-f0-9]{64}$/u.test(value.releaseId) || !/^[a-f0-9]{64}$/u.test(value.sha256) || value.releaseId !== `amobile_ios_${value.sha256}`) {
|
|
2711
|
+
throw new TypeError("Invalid AbsoluteJS iOS release metadata.");
|
|
2712
|
+
}
|
|
2713
|
+
return {
|
|
2714
|
+
appBuild: value.appBuild,
|
|
2715
|
+
appId: value.appId,
|
|
2716
|
+
artifact: value.artifact,
|
|
2717
|
+
...typeof value.buildNumber === "number" ? { buildNumber: value.buildNumber } : {},
|
|
2718
|
+
bytes: value.bytes,
|
|
2719
|
+
engine: value.engine,
|
|
2720
|
+
format: value.format,
|
|
2721
|
+
marketingVersion: value.marketingVersion,
|
|
2722
|
+
platform: value.platform,
|
|
2723
|
+
releaseId: value.releaseId,
|
|
2724
|
+
runtime: value.runtime,
|
|
2725
|
+
sha256: value.sha256,
|
|
2726
|
+
signed: value.signed,
|
|
2727
|
+
type: value.type
|
|
2728
|
+
};
|
|
2729
|
+
};
|
|
2709
2730
|
var installRelease2 = async (artifactPath, metadata, outputRoot) => {
|
|
2710
2731
|
const releaseRoot = join5(outputRoot, metadata.releaseId);
|
|
2711
2732
|
const destination = join5(releaseRoot, "App.ipa");
|
|
@@ -2854,6 +2875,17 @@ var buildAbsoluteIosRelease = async (options) => {
|
|
|
2854
2875
|
});
|
|
2855
2876
|
}
|
|
2856
2877
|
};
|
|
2878
|
+
var installAbsoluteIosRelease = async (options) => {
|
|
2879
|
+
const metadata = requireAbsoluteIosReleaseMetadata(options.metadata);
|
|
2880
|
+
const [bytes, sha256] = await Promise.all([
|
|
2881
|
+
stat2(options.artifactPath).then(({ size }) => size),
|
|
2882
|
+
sha256File2(options.artifactPath)
|
|
2883
|
+
]);
|
|
2884
|
+
if (bytes !== metadata.bytes || sha256 !== metadata.sha256)
|
|
2885
|
+
throw new TypeError("Remote iOS release artifact does not match its signed metadata.");
|
|
2886
|
+
const { artifact: _artifact, ...releaseMetadata } = metadata;
|
|
2887
|
+
return installRelease2(options.artifactPath, releaseMetadata, safeOutputDirectory2(options.projectRoot, options.outputDirectory));
|
|
2888
|
+
};
|
|
2857
2889
|
// src/mobile/iosConformance.ts
|
|
2858
2890
|
import { readFile as readFile6, stat as stat3 } from "fs/promises";
|
|
2859
2891
|
var HMR_LINE = new RegExp(String.raw`\[hmr:ios\]\s+([^\n]*?)\s+(applied in|falling back to reload after|failed after)\s+(\d+)ms(?:; server\s+(\d+)ms, client\s+(\d+)ms)?`, "u");
|
|
@@ -4072,7 +4104,15 @@ var createAbsoluteIosNativeWatcher = async (options) => {
|
|
|
4072
4104
|
var isAbsoluteIosNativeRootInput = (path) => ROOT_NATIVE_INPUTS.has(basename(path));
|
|
4073
4105
|
// src/mobile/remoteMacProtocol.ts
|
|
4074
4106
|
import { createHash as createHash7, randomUUID as randomUUID4 } from "crypto";
|
|
4075
|
-
import {
|
|
4107
|
+
import {
|
|
4108
|
+
chmod,
|
|
4109
|
+
mkdir as mkdir6,
|
|
4110
|
+
mkdtemp as mkdtemp4,
|
|
4111
|
+
readFile as readFile9,
|
|
4112
|
+
rename as rename7,
|
|
4113
|
+
rm as rm6,
|
|
4114
|
+
writeFile as writeFile7
|
|
4115
|
+
} from "fs/promises";
|
|
4076
4116
|
import { homedir as homedir2 } from "os";
|
|
4077
4117
|
import { isIP as isIP3 } from "net";
|
|
4078
4118
|
import {
|
|
@@ -4087,7 +4127,7 @@ import {
|
|
|
4087
4127
|
|
|
4088
4128
|
// src/mobile/remoteMacWire.ts
|
|
4089
4129
|
var ABSOLUTE_REMOTE_MAC_EVENT_PREFIX = "ABSOLUTE_REMOTE_MAC\t";
|
|
4090
|
-
var ABSOLUTE_REMOTE_MAC_PROTOCOL_VERSION =
|
|
4130
|
+
var ABSOLUTE_REMOTE_MAC_PROTOCOL_VERSION = 3;
|
|
4091
4131
|
|
|
4092
4132
|
// src/mobile/remoteMacProtocol.ts
|
|
4093
4133
|
var PROFILE_FORMAT = 1;
|
|
@@ -4446,6 +4486,13 @@ var absoluteRemoteProjectSyncCommands = (project) => {
|
|
|
4446
4486
|
tar: [
|
|
4447
4487
|
"tar",
|
|
4448
4488
|
"--exclude=.git",
|
|
4489
|
+
"--exclude=.env",
|
|
4490
|
+
"--exclude=.env.*",
|
|
4491
|
+
"--exclude=*.jks",
|
|
4492
|
+
"--exclude=*.keystore",
|
|
4493
|
+
"--exclude=*.mobileprovision",
|
|
4494
|
+
"--exclude=*.p12",
|
|
4495
|
+
"--exclude=*.p8",
|
|
4449
4496
|
"--exclude=node_modules",
|
|
4450
4497
|
"--exclude=build",
|
|
4451
4498
|
"--exclude=.absolutejs",
|
|
@@ -4483,6 +4530,113 @@ var syncAbsoluteRemoteMacProject = async (project) => {
|
|
|
4483
4530
|
]);
|
|
4484
4531
|
requireRemoteSuccess(install, "Remote Mac dependency installation");
|
|
4485
4532
|
};
|
|
4533
|
+
var requireRemoteProjectRelativePath = (project, path) => {
|
|
4534
|
+
const value = portableRelativePath(project.projectRoot, path);
|
|
4535
|
+
if (!value || value === ".." || value.startsWith("../") || posix.isAbsolute(value))
|
|
4536
|
+
throw new TypeError("Remote iOS release inputs must remain inside the project.");
|
|
4537
|
+
return value;
|
|
4538
|
+
};
|
|
4539
|
+
var absoluteRemoteReleaseInputSyncCommands = (project) => {
|
|
4540
|
+
const relativeBundle = requireRemoteProjectRelativePath(project, project.config.bundleDirectory);
|
|
4541
|
+
const destination = posix.join(project.remoteProjectRoot, relativeBundle);
|
|
4542
|
+
const staging = `${destination}.incoming-${randomUUID4()}`;
|
|
4543
|
+
const script = [
|
|
4544
|
+
"set -eu",
|
|
4545
|
+
`rm -rf ${shellQuote(staging)}`,
|
|
4546
|
+
`mkdir -p ${shellQuote(staging)}`,
|
|
4547
|
+
`tar -xf - -C ${shellQuote(staging)}`,
|
|
4548
|
+
`rm -rf ${shellQuote(destination)}`,
|
|
4549
|
+
`mkdir -p ${shellQuote(posix.dirname(destination))}`,
|
|
4550
|
+
`mv ${shellQuote(staging)} ${shellQuote(destination)}`
|
|
4551
|
+
].join("; ");
|
|
4552
|
+
return {
|
|
4553
|
+
remote: [
|
|
4554
|
+
...absoluteRemoteMacSshBase(project.profile),
|
|
4555
|
+
"/bin/sh -lc",
|
|
4556
|
+
shellQuote(script)
|
|
4557
|
+
],
|
|
4558
|
+
tar: ["tar", "-cf", "-", "-C", project.config.bundleDirectory, "."]
|
|
4559
|
+
};
|
|
4560
|
+
};
|
|
4561
|
+
var syncAbsoluteRemoteMacReleaseInputs = async (project) => {
|
|
4562
|
+
const commands = absoluteRemoteReleaseInputSyncCommands(project);
|
|
4563
|
+
const archive = Bun.spawn(commands.tar, {
|
|
4564
|
+
stderr: "pipe",
|
|
4565
|
+
stdout: "pipe"
|
|
4566
|
+
});
|
|
4567
|
+
const upload = Bun.spawn(commands.remote, {
|
|
4568
|
+
stderr: "pipe",
|
|
4569
|
+
stdin: archive.stdout,
|
|
4570
|
+
stdout: "pipe"
|
|
4571
|
+
});
|
|
4572
|
+
const [archiveExit, uploadExit, archiveError, uploadError] = await Promise.all([
|
|
4573
|
+
archive.exited,
|
|
4574
|
+
upload.exited,
|
|
4575
|
+
new Response(archive.stderr).text(),
|
|
4576
|
+
new Response(upload.stderr).text()
|
|
4577
|
+
]);
|
|
4578
|
+
if (archiveExit !== 0 || uploadExit !== 0)
|
|
4579
|
+
throw new Error(`Remote iOS release input synchronization failed: ${(archiveError || uploadError).trim()}`);
|
|
4580
|
+
};
|
|
4581
|
+
var writeRemoteArtifact = async (path, stream) => {
|
|
4582
|
+
const sink = Bun.file(path).writer();
|
|
4583
|
+
const reader = stream.getReader();
|
|
4584
|
+
try {
|
|
4585
|
+
while (true) {
|
|
4586
|
+
const { done, value } = await reader.read();
|
|
4587
|
+
if (done)
|
|
4588
|
+
break;
|
|
4589
|
+
sink.write(value);
|
|
4590
|
+
}
|
|
4591
|
+
await sink.end();
|
|
4592
|
+
} catch (error) {
|
|
4593
|
+
await Promise.resolve(sink.end()).catch(() => {
|
|
4594
|
+
return;
|
|
4595
|
+
});
|
|
4596
|
+
throw error;
|
|
4597
|
+
} finally {
|
|
4598
|
+
reader.releaseLock();
|
|
4599
|
+
}
|
|
4600
|
+
};
|
|
4601
|
+
var retrieveAbsoluteRemoteIosRelease = async (project, metadata, outputDirectory) => {
|
|
4602
|
+
const releaseRoot = posix.join(project.remoteProjectRoot, ".absolutejs", "mobile", "releases", "ios", metadata.releaseId);
|
|
4603
|
+
const stagingParent = join7(project.projectRoot, ".absolutejs", "mobile");
|
|
4604
|
+
await mkdir6(stagingParent, { recursive: true });
|
|
4605
|
+
const staging = await mkdtemp4(join7(stagingParent, ".remote-ios-"));
|
|
4606
|
+
try {
|
|
4607
|
+
const remoteMetadata = requireRemoteSuccess(await defaultTransport.capture([
|
|
4608
|
+
...absoluteRemoteMacSshBase(project.profile),
|
|
4609
|
+
"/bin/sh -lc",
|
|
4610
|
+
shellQuote(`cat ${shellQuote(posix.join(releaseRoot, "release.json"))}`)
|
|
4611
|
+
]), "Remote iOS release metadata retrieval");
|
|
4612
|
+
const downloadedMetadata = JSON.parse(remoteMetadata);
|
|
4613
|
+
if (JSON.stringify(requireAbsoluteIosReleaseMetadata(downloadedMetadata)) !== JSON.stringify(metadata))
|
|
4614
|
+
throw new TypeError("Remote iOS release metadata changed during retrieval.");
|
|
4615
|
+
const artifactPath = join7(staging, "App.ipa");
|
|
4616
|
+
const download = Bun.spawn([
|
|
4617
|
+
...absoluteRemoteMacSshBase(project.profile),
|
|
4618
|
+
"/bin/sh -lc",
|
|
4619
|
+
shellQuote(`cat ${shellQuote(posix.join(releaseRoot, "App.ipa"))}`)
|
|
4620
|
+
], { stderr: "pipe", stdout: "pipe" });
|
|
4621
|
+
const [downloadExit, downloadError] = await Promise.all([
|
|
4622
|
+
download.exited,
|
|
4623
|
+
new Response(download.stderr).text(),
|
|
4624
|
+
writeRemoteArtifact(artifactPath, download.stdout)
|
|
4625
|
+
]);
|
|
4626
|
+
if (downloadExit !== 0)
|
|
4627
|
+
throw new Error(`Remote iOS release retrieval failed: ${downloadError.trim()}`);
|
|
4628
|
+
return await installAbsoluteIosRelease({
|
|
4629
|
+
artifactPath,
|
|
4630
|
+
metadata,
|
|
4631
|
+
outputDirectory,
|
|
4632
|
+
projectRoot: project.projectRoot
|
|
4633
|
+
});
|
|
4634
|
+
} finally {
|
|
4635
|
+
await rm6(staging, { force: true, recursive: true }).catch(() => {
|
|
4636
|
+
return;
|
|
4637
|
+
});
|
|
4638
|
+
}
|
|
4639
|
+
};
|
|
4486
4640
|
var consumeLines2 = async (stream, onLine) => {
|
|
4487
4641
|
const reader = stream.getReader();
|
|
4488
4642
|
const decoder = new TextDecoder;
|
|
@@ -4504,6 +4658,117 @@ var consumeLines2 = async (stream, onLine) => {
|
|
|
4504
4658
|
reader.releaseLock();
|
|
4505
4659
|
}
|
|
4506
4660
|
};
|
|
4661
|
+
var buildAbsoluteRemoteIosRelease = async (options) => {
|
|
4662
|
+
const startedAt = performance.now();
|
|
4663
|
+
const syncStartedAt = performance.now();
|
|
4664
|
+
await (options.syncProject ?? syncAbsoluteRemoteMacProject)(options.project);
|
|
4665
|
+
await (options.syncReleaseInputs ?? syncAbsoluteRemoteMacReleaseInputs)(options.project);
|
|
4666
|
+
const syncDuration = performance.now() - syncStartedAt;
|
|
4667
|
+
options.onPhaseTiming?.({
|
|
4668
|
+
durationMs: syncDuration,
|
|
4669
|
+
phase: "remote-release-sync"
|
|
4670
|
+
});
|
|
4671
|
+
const agentStartedAt = performance.now();
|
|
4672
|
+
const agent = await (options.installAgent ?? installAbsoluteRemoteMacAgent)(options.project);
|
|
4673
|
+
const agentDuration = performance.now() - agentStartedAt;
|
|
4674
|
+
const encodedConfig = Buffer.from(JSON.stringify(portableMobileConfig(options.project))).toString("base64url");
|
|
4675
|
+
const remoteCommand = [
|
|
4676
|
+
`cd ${shellQuote(options.project.remoteProjectRoot)}`,
|
|
4677
|
+
"&&",
|
|
4678
|
+
"exec",
|
|
4679
|
+
shellQuote(options.project.profile.bunPath),
|
|
4680
|
+
shellQuote(agent.remotePath),
|
|
4681
|
+
"--release-ios",
|
|
4682
|
+
"--mobile-config",
|
|
4683
|
+
shellQuote(encodedConfig),
|
|
4684
|
+
...options.allowUnsigned ? ["--unsigned"] : [],
|
|
4685
|
+
...options.prepareBuildNumber ? ["--request-build-number"] : [],
|
|
4686
|
+
...options.developmentTeam ? ["--development-team", shellQuote(options.developmentTeam)] : []
|
|
4687
|
+
].join(" ");
|
|
4688
|
+
const process2 = (options.transport?.spawn ?? defaultTransport.spawn)([
|
|
4689
|
+
...absoluteRemoteMacSshBase(options.project.profile),
|
|
4690
|
+
"/bin/sh -lc",
|
|
4691
|
+
shellQuote(remoteCommand)
|
|
4692
|
+
], {});
|
|
4693
|
+
let failure;
|
|
4694
|
+
let metadata;
|
|
4695
|
+
const responses = [];
|
|
4696
|
+
const stdoutDone = consumeLines2(process2.stdout, (line) => {
|
|
4697
|
+
if (!line.startsWith(ABSOLUTE_REMOTE_MAC_EVENT_PREFIX))
|
|
4698
|
+
return;
|
|
4699
|
+
try {
|
|
4700
|
+
const event = JSON.parse(line.slice(ABSOLUTE_REMOTE_MAC_EVENT_PREFIX.length));
|
|
4701
|
+
if (event.v !== ABSOLUTE_REMOTE_MAC_PROTOCOL_VERSION)
|
|
4702
|
+
throw new Error("Remote Mac protocol version mismatch.");
|
|
4703
|
+
if (event.type === "log")
|
|
4704
|
+
options.log?.(event.message);
|
|
4705
|
+
if (event.type === "timing") {
|
|
4706
|
+
const durationMs = Reflect.get(event, "durationMs");
|
|
4707
|
+
const phase = Reflect.get(event, "phase");
|
|
4708
|
+
if (typeof durationMs === "number" && typeof phase === "string")
|
|
4709
|
+
options.onPhaseTiming?.({ durationMs, phase });
|
|
4710
|
+
}
|
|
4711
|
+
if (event.type === "fatal")
|
|
4712
|
+
failure = new Error(event.error);
|
|
4713
|
+
if (event.type === "release")
|
|
4714
|
+
metadata = requireAbsoluteIosReleaseMetadata(event.metadata);
|
|
4715
|
+
if (event.type === "build-number-request") {
|
|
4716
|
+
if (!options.prepareBuildNumber || !/^[a-f0-9]{64}$/u.test(event.buildIdentity) || !event.id)
|
|
4717
|
+
throw new TypeError("Remote Mac requested an invalid iOS build number.");
|
|
4718
|
+
responses.push(options.prepareBuildNumber(event.buildIdentity).then(async (buildNumber) => {
|
|
4719
|
+
if (!Number.isSafeInteger(buildNumber) || buildNumber < 1)
|
|
4720
|
+
throw new TypeError("iOS release publisher returned an invalid build number.");
|
|
4721
|
+
process2.stdin.write(`${JSON.stringify({ buildNumber, command: "build-number", id: event.id, v: ABSOLUTE_REMOTE_MAC_PROTOCOL_VERSION })}
|
|
4722
|
+
`);
|
|
4723
|
+
for (let attempt = 0;attempt < REMOTE_STDIN_FLUSH_ATTEMPTS; attempt++) {
|
|
4724
|
+
try {
|
|
4725
|
+
await process2.stdin.flush();
|
|
4726
|
+
break;
|
|
4727
|
+
} catch {
|
|
4728
|
+
await Promise.resolve();
|
|
4729
|
+
}
|
|
4730
|
+
}
|
|
4731
|
+
}).catch((error) => {
|
|
4732
|
+
failure = error instanceof Error ? error : new Error("Failed to allocate an iOS build number.");
|
|
4733
|
+
process2.kill();
|
|
4734
|
+
return;
|
|
4735
|
+
}));
|
|
4736
|
+
}
|
|
4737
|
+
} catch (error) {
|
|
4738
|
+
failure = error instanceof Error ? error : new Error("Remote Mac emitted an invalid release event.");
|
|
4739
|
+
process2.kill();
|
|
4740
|
+
}
|
|
4741
|
+
});
|
|
4742
|
+
const stderrDone = consumeLines2(process2.stderr, (line) => options.log?.(`[remote] ${line}`));
|
|
4743
|
+
const exitCode = await process2.exited;
|
|
4744
|
+
try {
|
|
4745
|
+
process2.stdin.end();
|
|
4746
|
+
} catch {}
|
|
4747
|
+
await Promise.all([stdoutDone, stderrDone, ...responses]);
|
|
4748
|
+
if (failure)
|
|
4749
|
+
throw failure;
|
|
4750
|
+
if (exitCode !== 0)
|
|
4751
|
+
throw new Error(`Remote iOS release agent exited with status ${exitCode}.`);
|
|
4752
|
+
if (!metadata)
|
|
4753
|
+
throw new Error("Remote iOS release agent did not return an IPA.");
|
|
4754
|
+
const downloadStartedAt = performance.now();
|
|
4755
|
+
const release = await (options.retrieveRelease ?? retrieveAbsoluteRemoteIosRelease)(options.project, metadata, options.outputDirectory);
|
|
4756
|
+
const downloadDuration = performance.now() - downloadStartedAt;
|
|
4757
|
+
options.onPhaseTiming?.({
|
|
4758
|
+
durationMs: downloadDuration,
|
|
4759
|
+
phase: "remote-release-download"
|
|
4760
|
+
});
|
|
4761
|
+
options.log?.(`Remote Mac ${options.project.profile.name} built and verified iOS release ${metadata.releaseId} in ${(performance.now() - startedAt).toFixed(2)}ms (agent ${agent.uploaded ? "uploaded" : "cache hit"}).`);
|
|
4762
|
+
return {
|
|
4763
|
+
...release,
|
|
4764
|
+
timings: {
|
|
4765
|
+
"remote-agent": agentDuration,
|
|
4766
|
+
"remote-release-download": downloadDuration,
|
|
4767
|
+
"remote-release-sync": syncDuration,
|
|
4768
|
+
total: performance.now() - startedAt
|
|
4769
|
+
}
|
|
4770
|
+
};
|
|
4771
|
+
};
|
|
4507
4772
|
var startAbsoluteRemoteExpoIosDevSession = async (options) => {
|
|
4508
4773
|
const session = await startAbsoluteRemoteDevSession({
|
|
4509
4774
|
certificateAuthorityPath: options.certificateAuthorityPath,
|
|
@@ -4679,7 +4944,9 @@ var startAbsoluteRemoteDevSession = async (options) => {
|
|
|
4679
4944
|
try {
|
|
4680
4945
|
await readyPromise;
|
|
4681
4946
|
} catch (error) {
|
|
4682
|
-
|
|
4947
|
+
try {
|
|
4948
|
+
process2.stdin.end();
|
|
4949
|
+
} catch {}
|
|
4683
4950
|
process2.kill();
|
|
4684
4951
|
await process2.exited.catch(() => {
|
|
4685
4952
|
return;
|
|
@@ -4731,13 +4998,12 @@ var startAbsoluteRemoteDevSession = async (options) => {
|
|
|
4731
4998
|
return;
|
|
4732
4999
|
closed = true;
|
|
4733
5000
|
const timeout = () => new Promise((resolve6) => setTimeout(() => resolve6("timeout"), REMOTE_SESSION_CLOSE_TIMEOUT_MS));
|
|
4734
|
-
|
|
4735
|
-
|
|
4736
|
-
|
|
4737
|
-
|
|
4738
|
-
|
|
4739
|
-
|
|
4740
|
-
process2.stdin.end();
|
|
5001
|
+
const id = randomUUID4();
|
|
5002
|
+
process2.stdin.write(`${JSON.stringify({ command: "close", id, v: ABSOLUTE_REMOTE_MAC_PROTOCOL_VERSION })}
|
|
5003
|
+
`);
|
|
5004
|
+
try {
|
|
5005
|
+
process2.stdin.end();
|
|
5006
|
+
} catch {}
|
|
4741
5007
|
const exit = await Promise.race([
|
|
4742
5008
|
process2.exited.then(() => "exited").catch(() => "exited"),
|
|
4743
5009
|
timeout()
|
|
@@ -4837,7 +5103,7 @@ import {
|
|
|
4837
5103
|
mkdir as mkdir7,
|
|
4838
5104
|
readFile as readFile10,
|
|
4839
5105
|
rename as rename8,
|
|
4840
|
-
rm as
|
|
5106
|
+
rm as rm7,
|
|
4841
5107
|
writeFile as writeFile8
|
|
4842
5108
|
} from "fs/promises";
|
|
4843
5109
|
import { resolve as resolve7 } from "path";
|
|
@@ -4970,7 +5236,7 @@ var publishGeneratedDirectory = async (temporary, root) => {
|
|
|
4970
5236
|
throw error;
|
|
4971
5237
|
}
|
|
4972
5238
|
if (hasCurrent)
|
|
4973
|
-
await
|
|
5239
|
+
await rm7(backup, { force: true, recursive: true });
|
|
4974
5240
|
};
|
|
4975
5241
|
var materializeHost = async (root, host, files) => {
|
|
4976
5242
|
const directory = resolve7(root, host, ".well-known");
|
|
@@ -5021,7 +5287,7 @@ var materializeAbsoluteMobileAssociationFiles = async (config, outputDirectory)
|
|
|
5021
5287
|
const written = temporaryPaths.map((path) => resolve7(root, path.slice(temporary.length + 1)));
|
|
5022
5288
|
return { root, written };
|
|
5023
5289
|
} catch (error) {
|
|
5024
|
-
await
|
|
5290
|
+
await rm7(temporary, { force: true, recursive: true });
|
|
5025
5291
|
throw error;
|
|
5026
5292
|
}
|
|
5027
5293
|
};
|
|
@@ -5242,10 +5508,10 @@ import {
|
|
|
5242
5508
|
cp,
|
|
5243
5509
|
copyFile as copyFile5,
|
|
5244
5510
|
mkdir as mkdir9,
|
|
5245
|
-
mkdtemp as
|
|
5511
|
+
mkdtemp as mkdtemp5,
|
|
5246
5512
|
readFile as readFile12,
|
|
5247
5513
|
rename as rename9,
|
|
5248
|
-
rm as
|
|
5514
|
+
rm as rm8,
|
|
5249
5515
|
writeFile as writeFile10
|
|
5250
5516
|
} from "fs/promises";
|
|
5251
5517
|
import { existsSync as existsSync2 } from "fs";
|
|
@@ -5902,12 +6168,12 @@ void startAbsoluteMobileShell(${shellOptions});
|
|
|
5902
6168
|
throw new AggregateError(build.logs, "Failed to build the AbsoluteJS Capacitor shell.");
|
|
5903
6169
|
}
|
|
5904
6170
|
await rename9(build.outputs[0]?.path ?? "", join9(staging, BOOTSTRAP_FILE));
|
|
5905
|
-
await
|
|
6171
|
+
await rm8(entryPath, { force: true });
|
|
5906
6172
|
};
|
|
5907
6173
|
var removePreviousBundle = async (backup, moved) => {
|
|
5908
6174
|
if (!moved)
|
|
5909
6175
|
return;
|
|
5910
|
-
await
|
|
6176
|
+
await rm8(backup, { force: true, recursive: true });
|
|
5911
6177
|
};
|
|
5912
6178
|
var restorePreviousBundle = async (backup, destination, moved) => {
|
|
5913
6179
|
if (!moved)
|
|
@@ -6011,7 +6277,7 @@ var materializeAbsoluteCapacitorWebBundle = async (options) => {
|
|
|
6011
6277
|
}
|
|
6012
6278
|
const destination = options.config.bundleDirectory;
|
|
6013
6279
|
await mkdir9(dirname7(destination), { recursive: true });
|
|
6014
|
-
const staging = await
|
|
6280
|
+
const staging = await mkdtemp5(join9(dirname7(destination), `.${basename3(destination)}.stage-`));
|
|
6015
6281
|
try {
|
|
6016
6282
|
const pageDirectory = join9(staging, "pages");
|
|
6017
6283
|
await mkdir9(pageDirectory, { recursive: true });
|
|
@@ -6059,7 +6325,7 @@ var materializeAbsoluteCapacitorWebBundle = async (options) => {
|
|
|
6059
6325
|
await installBundle(staging, destination);
|
|
6060
6326
|
return manifest;
|
|
6061
6327
|
} catch (error) {
|
|
6062
|
-
await
|
|
6328
|
+
await rm8(staging, { force: true, recursive: true });
|
|
6063
6329
|
throw error;
|
|
6064
6330
|
}
|
|
6065
6331
|
};
|
|
@@ -6072,10 +6338,10 @@ import { createHash as createHash9 } from "crypto";
|
|
|
6072
6338
|
import {
|
|
6073
6339
|
access as access8,
|
|
6074
6340
|
mkdir as mkdir10,
|
|
6075
|
-
mkdtemp as
|
|
6341
|
+
mkdtemp as mkdtemp6,
|
|
6076
6342
|
readFile as readFile13,
|
|
6077
6343
|
rename as rename10,
|
|
6078
|
-
rm as
|
|
6344
|
+
rm as rm9,
|
|
6079
6345
|
writeFile as writeFile11
|
|
6080
6346
|
} from "fs/promises";
|
|
6081
6347
|
import { dirname as dirname8, join as join10, resolve as resolvePath3 } from "path";
|
|
@@ -6136,12 +6402,12 @@ var installImmutableBundle = async (bundlesRoot, bundleId, releases) => {
|
|
|
6136
6402
|
if (!errorHasCode3(error, "ENOENT"))
|
|
6137
6403
|
throw error;
|
|
6138
6404
|
}
|
|
6139
|
-
const staging = await
|
|
6405
|
+
const staging = await mkdtemp6(join10(bundlesRoot, ".stage-"));
|
|
6140
6406
|
try {
|
|
6141
6407
|
await Promise.all(releases.map((release) => writeRelease(staging, release)));
|
|
6142
6408
|
await rename10(staging, destination);
|
|
6143
6409
|
} catch (error) {
|
|
6144
|
-
await
|
|
6410
|
+
await rm9(staging, { force: true, recursive: true });
|
|
6145
6411
|
if (errorHasCode3(error, "EEXIST") || errorHasCode3(error, "ENOTEMPTY")) {
|
|
6146
6412
|
return destination;
|
|
6147
6413
|
}
|
|
@@ -6257,11 +6523,11 @@ import {
|
|
|
6257
6523
|
access as access9,
|
|
6258
6524
|
cp as cp2,
|
|
6259
6525
|
mkdir as mkdir11,
|
|
6260
|
-
mkdtemp as
|
|
6526
|
+
mkdtemp as mkdtemp7,
|
|
6261
6527
|
readdir as readdir4,
|
|
6262
6528
|
readFile as readFile14,
|
|
6263
6529
|
rename as rename11,
|
|
6264
|
-
rm as
|
|
6530
|
+
rm as rm10,
|
|
6265
6531
|
writeFile as writeFile12
|
|
6266
6532
|
} from "fs/promises";
|
|
6267
6533
|
import { createHash as createHash10 } from "crypto";
|
|
@@ -7303,7 +7569,7 @@ var pruneStaleManagedExpoRoutes = async (project, expected) => {
|
|
|
7303
7569
|
managed: path.endsWith(".tsx") && (await readFile14(path, "utf8")).startsWith(EXPO_GENERATED_HEADER),
|
|
7304
7570
|
path
|
|
7305
7571
|
})))).filter(({ managed, path }) => managed && !expected.has(path));
|
|
7306
|
-
await Promise.all(stale.map(({ path }) =>
|
|
7572
|
+
await Promise.all(stale.map(({ path }) => rm10(path, { force: true })));
|
|
7307
7573
|
return stale.length;
|
|
7308
7574
|
};
|
|
7309
7575
|
var jsonSource = (value) => `${JSON.stringify(value, null, "\t")}
|
|
@@ -7453,7 +7719,7 @@ var installStagedDirectory = async (staging, destination) => {
|
|
|
7453
7719
|
try {
|
|
7454
7720
|
await rename11(staging, destination);
|
|
7455
7721
|
if (moved)
|
|
7456
|
-
await
|
|
7722
|
+
await rm10(backup, { force: true, recursive: true });
|
|
7457
7723
|
} catch (error) {
|
|
7458
7724
|
if (moved)
|
|
7459
7725
|
await rename11(backup, destination);
|
|
@@ -7514,7 +7780,7 @@ var syncAbsoluteExpoWebAssets = async (config) => {
|
|
|
7514
7780
|
const bundleId = `amexpo_${bundleHash.digest("hex")}`;
|
|
7515
7781
|
const destination = join14(config.nativeProjectDirectory, "assets", "absolute");
|
|
7516
7782
|
await mkdir11(dirname10(destination), { recursive: true });
|
|
7517
|
-
const staging = await
|
|
7783
|
+
const staging = await mkdtemp7(join14(dirname10(destination), `.${basename4(destination)}.stage-`));
|
|
7518
7784
|
let assets;
|
|
7519
7785
|
try {
|
|
7520
7786
|
assets = await Promise.all(files.map(async (source, index) => {
|
|
@@ -7527,7 +7793,7 @@ var syncAbsoluteExpoWebAssets = async (config) => {
|
|
|
7527
7793
|
}));
|
|
7528
7794
|
await installStagedDirectory(staging, destination);
|
|
7529
7795
|
} catch (error) {
|
|
7530
|
-
await
|
|
7796
|
+
await rm10(staging, { force: true, recursive: true });
|
|
7531
7797
|
throw error;
|
|
7532
7798
|
}
|
|
7533
7799
|
const generated = join14(config.nativeProjectDirectory, "src", "generated", "webAssets.ts");
|
|
@@ -10437,6 +10703,7 @@ export {
|
|
|
10437
10703
|
absoluteMobilePreviewDocument,
|
|
10438
10704
|
absoluteRemoteMacSshBase,
|
|
10439
10705
|
absoluteRemoteProjectSyncCommands,
|
|
10706
|
+
absoluteRemoteReleaseInputSyncCommands,
|
|
10440
10707
|
acceptsAbsoluteMobilePage,
|
|
10441
10708
|
acceptsAbsoluteNativeRouteData,
|
|
10442
10709
|
activateAbsoluteMobilePage,
|
|
@@ -10446,6 +10713,7 @@ export {
|
|
|
10446
10713
|
buildAbsoluteAndroidRelease,
|
|
10447
10714
|
buildAbsoluteIosRelease,
|
|
10448
10715
|
buildAbsoluteMobileCompatibilityRelease,
|
|
10716
|
+
buildAbsoluteRemoteIosRelease,
|
|
10449
10717
|
captureAbsoluteMobileRouteGraph,
|
|
10450
10718
|
captureAbsoluteRemoteMacCommand,
|
|
10451
10719
|
carryForwardAbsoluteMobileCompatibilityReleases,
|
|
@@ -10485,6 +10753,7 @@ export {
|
|
|
10485
10753
|
inspectAbsoluteMobileRouteMetadata,
|
|
10486
10754
|
inspectAbsoluteRemoteMac,
|
|
10487
10755
|
inspectAbsoluteRemoteMacLanHost,
|
|
10756
|
+
installAbsoluteIosRelease,
|
|
10488
10757
|
installAbsoluteMobileAuthEnvironment,
|
|
10489
10758
|
installAbsoluteMobileShellHttp,
|
|
10490
10759
|
installAbsoluteMobileSyncRemediation,
|
|
@@ -10529,6 +10798,7 @@ export {
|
|
|
10529
10798
|
redactAbsoluteIosLog,
|
|
10530
10799
|
removeAbsoluteRemoteMacProfile,
|
|
10531
10800
|
repairAbsoluteIosDevSession,
|
|
10801
|
+
requireAbsoluteIosReleaseMetadata,
|
|
10532
10802
|
resolveAbsoluteDeviceCapabilityPlan,
|
|
10533
10803
|
resolveAbsoluteIosXcodeProject,
|
|
10534
10804
|
resolveAbsoluteMobileAuthManifest,
|
|
@@ -10548,6 +10818,7 @@ export {
|
|
|
10548
10818
|
startAbsoluteRemoteIosDevSession,
|
|
10549
10819
|
syncAbsoluteExpoWebAssets,
|
|
10550
10820
|
syncAbsoluteRemoteMacProject,
|
|
10821
|
+
syncAbsoluteRemoteMacReleaseInputs,
|
|
10551
10822
|
testAbsoluteIosPhysicalDevice,
|
|
10552
10823
|
validateAbsoluteRemoteMacProfileName,
|
|
10553
10824
|
validateAbsoluteSshDestination,
|
|
@@ -10559,5 +10830,5 @@ export {
|
|
|
10559
10830
|
writeAbsoluteMobileGithubWorkflow
|
|
10560
10831
|
};
|
|
10561
10832
|
|
|
10562
|
-
//# debugId=
|
|
10833
|
+
//# debugId=F76EB3F5E0BCCF1964756E2164756E21
|
|
10563
10834
|
//# sourceMappingURL=index.js.map
|