peachsim 0.1.714 → 0.1.716
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/cli/commands/install-desktop.ts +74 -20
- package/cli/desktop-companion.ts +11 -6
- package/dist-lib/agent-daemon-client.cjs +1 -1
- package/dist-lib/agent-events.cjs +1 -1
- package/dist-lib/agent-identity.cjs +1 -1
- package/dist-lib/agent-sessions.cjs +1 -1
- package/dist-lib/attached-projects.cjs +1 -1
- package/dist-lib/auth/shared-session.cjs +1 -1
- package/dist-lib/backend-origin.cjs +1 -1
- package/dist-lib/beta.cjs +1 -1
- package/dist-lib/beta.mjs +1 -1
- package/dist-lib/bridge-constants.cjs +1 -1
- package/dist-lib/bridge-contract-input.cjs +1 -1
- package/dist-lib/bridge-contract-input.mjs +1 -1
- package/dist-lib/bridge-contract.cjs +1 -1
- package/dist-lib/bridge-contract.mjs +1 -1
- package/dist-lib/capture-contract.cjs +1 -1
- package/dist-lib/capture-contract.mjs +1 -1
- package/dist-lib/cli-constants.cjs +1 -1
- package/dist-lib/cloud-contract.cjs +1 -1
- package/dist-lib/cloud-contract.mjs +1 -1
- package/dist-lib/cloud-test-args.cjs +1 -1
- package/dist-lib/cloud-test-args.mjs +1 -1
- package/dist-lib/cloud.cjs +1 -1
- package/dist-lib/cloud.mjs +1 -1
- package/dist-lib/config.cjs +1 -1
- package/dist-lib/detox/index.cjs +1 -1
- package/dist-lib/dev-bundle-resolution.cjs +1 -1
- package/dist-lib/home-paths.cjs +1 -1
- package/dist-lib/host/bridge-host.cjs +71 -25
- package/dist-lib/host/fetch-proxy-handler.cjs +1 -1
- package/dist-lib/host/fetch-proxy-overrides.cjs +1 -1
- package/dist-lib/host/fetch-proxy-overrides.mjs +1 -1
- package/dist-lib/host/replacement-module-handler.cjs +1 -1
- package/dist-lib/host/websocket-proxy.cjs +1 -1
- package/dist-lib/index.cjs +1 -1
- package/dist-lib/jump-to-source-babel.cjs +1 -1
- package/dist-lib/jump-to-source-native.cjs +1 -1
- package/dist-lib/kotlin-host.cjs +1 -1
- package/dist-lib/menu.cjs +1 -1
- package/dist-lib/menu.mjs +1 -1
- package/dist-lib/metro-fingerprint-registry.cjs +1 -1
- package/dist-lib/metro-fingerprint-registry.mjs +1 -1
- package/dist-lib/metro-production-bundle.cjs +1 -1
- package/dist-lib/metro-production-bundle.mjs +1 -1
- package/dist-lib/metro.cjs +1 -1
- package/dist-lib/native-app-identity.cjs +1 -1
- package/dist-lib/native-app-identity.mjs +1 -1
- package/dist-lib/native-firebase-metadata.cjs +1 -1
- package/dist-lib/native-firebase-metadata.mjs +1 -1
- package/dist-lib/plist.cjs +1 -1
- package/dist-lib/plist.mjs +1 -1
- package/dist-lib/profiles.cjs +1 -1
- package/dist-lib/public-brand.cjs +1 -1
- package/dist-lib/react-native-host-modules.cjs +1 -1
- package/dist-lib/react-native-host-modules.mjs +1 -1
- package/dist-lib/render-mode.cjs +1 -1
- package/dist-lib/scripts/dev-server-scanner.cjs +1 -1
- package/dist-lib/sdk.cjs +1 -1
- package/dist-lib/sdk.mjs +1 -1
- package/dist-lib/skills.cjs +82 -31
- package/dist-lib/swift-compile.cjs +56 -21
- package/dist-lib/swift-compile.mjs +56 -21
- package/dist-lib/swift-package.cjs +27 -5
- package/dist-lib/swift-package.mjs +26 -5
- package/dist-lib/swift-submit.cjs +1 -1
- package/dist-lib/swift-submit.mjs +1 -1
- package/dist-lib/swift-toolchain.cjs +1 -1
- package/dist-lib/swift.cjs +1 -1
- package/dist-lib/vite-swift.cjs +63 -21
- package/dist-lib/vite.cjs +1 -1
- package/package.json +1 -1
- package/src/swift-compile.ts +43 -20
- package/src/swift-host.ts +9 -0
- package/src/swift-package.ts +42 -5
- package/src/swift-submit.ts +4 -0
package/dist-lib/index.cjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! rnx v0.1.
|
|
1
|
+
/*! rnx v0.1.716 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
|
|
2
2
|
let __sootsim_import_meta_url = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; } catch {}
|
|
3
3
|
"use strict";
|
|
4
4
|
var __create = Object.create;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! rnx v0.1.
|
|
1
|
+
/*! rnx v0.1.716 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
|
|
2
2
|
let __sootsim_import_meta_url = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; } catch {}
|
|
3
3
|
"use strict";
|
|
4
4
|
var __defProp = Object.defineProperty;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! rnx v0.1.
|
|
1
|
+
/*! rnx v0.1.716 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
|
|
2
2
|
let __sootsim_import_meta_url = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; } catch {}
|
|
3
3
|
"use strict";
|
|
4
4
|
var __create = Object.create;
|
package/dist-lib/kotlin-host.cjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! rnx v0.1.
|
|
1
|
+
/*! rnx v0.1.716 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
|
|
2
2
|
let __sootsim_import_meta_url = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; } catch {}
|
|
3
3
|
"use strict";
|
|
4
4
|
var __create = Object.create;
|
package/dist-lib/menu.cjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! rnx v0.1.
|
|
1
|
+
/*! rnx v0.1.716 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
|
|
2
2
|
let __sootsim_import_meta_url = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; } catch {}
|
|
3
3
|
"use strict";
|
|
4
4
|
var __defProp = Object.defineProperty;
|
package/dist-lib/menu.mjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! rnx v0.1.
|
|
1
|
+
/*! rnx v0.1.716 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
|
|
2
2
|
let __sootsim_import_meta_url = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; } catch {}
|
|
3
3
|
"use strict";
|
|
4
4
|
var __defProp = Object.defineProperty;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! rnx v0.1.
|
|
1
|
+
/*! rnx v0.1.716 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
|
|
2
2
|
let __sootsim_import_meta_url = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; } catch {}
|
|
3
3
|
"use strict";
|
|
4
4
|
var __defProp = Object.defineProperty;
|
package/dist-lib/metro.cjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! rnx v0.1.
|
|
1
|
+
/*! rnx v0.1.716 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
|
|
2
2
|
let __sootsim_import_meta_url = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; } catch {}
|
|
3
3
|
"use strict";
|
|
4
4
|
var __create = Object.create;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! rnx v0.1.
|
|
1
|
+
/*! rnx v0.1.716 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
|
|
2
2
|
let __sootsim_import_meta_url = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; } catch {}
|
|
3
3
|
"use strict";
|
|
4
4
|
var __defProp = Object.defineProperty;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! rnx v0.1.
|
|
1
|
+
/*! rnx v0.1.716 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
|
|
2
2
|
let __sootsim_import_meta_url = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; } catch {}
|
|
3
3
|
"use strict";
|
|
4
4
|
var __defProp = Object.defineProperty;
|
package/dist-lib/plist.cjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! rnx v0.1.
|
|
1
|
+
/*! rnx v0.1.716 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
|
|
2
2
|
let __sootsim_import_meta_url = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; } catch {}
|
|
3
3
|
"use strict";
|
|
4
4
|
var __create = Object.create;
|
package/dist-lib/plist.mjs
CHANGED
package/dist-lib/profiles.cjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! rnx v0.1.
|
|
1
|
+
/*! rnx v0.1.716 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
|
|
2
2
|
let __sootsim_import_meta_url = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; } catch {}
|
|
3
3
|
"use strict";
|
|
4
4
|
var __create = Object.create;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! rnx v0.1.
|
|
1
|
+
/*! rnx v0.1.716 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
|
|
2
2
|
let __sootsim_import_meta_url = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; } catch {}
|
|
3
3
|
"use strict";
|
|
4
4
|
var __defProp = Object.defineProperty;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! rnx v0.1.
|
|
1
|
+
/*! rnx v0.1.716 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
|
|
2
2
|
let __sootsim_import_meta_url = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; } catch {}
|
|
3
3
|
"use strict";
|
|
4
4
|
var __defProp = Object.defineProperty;
|
package/dist-lib/render-mode.cjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! rnx v0.1.
|
|
1
|
+
/*! rnx v0.1.716 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
|
|
2
2
|
let __sootsim_import_meta_url = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; } catch {}
|
|
3
3
|
"use strict";
|
|
4
4
|
var __defProp = Object.defineProperty;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! rnx v0.1.
|
|
1
|
+
/*! rnx v0.1.716 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
|
|
2
2
|
let __sootsim_import_meta_url = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; } catch {}
|
|
3
3
|
"use strict";
|
|
4
4
|
var __create = Object.create;
|
package/dist-lib/sdk.cjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! rnx v0.1.
|
|
1
|
+
/*! rnx v0.1.716 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
|
|
2
2
|
let __sootsim_import_meta_url = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; } catch {}
|
|
3
3
|
"use strict";
|
|
4
4
|
var __defProp = Object.defineProperty;
|
package/dist-lib/sdk.mjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! rnx v0.1.
|
|
1
|
+
/*! rnx v0.1.716 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
|
|
2
2
|
var __defProp = Object.defineProperty;
|
|
3
3
|
var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
4
4
|
var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "symbol" ? key + "" : key, value);
|
package/dist-lib/skills.cjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! rnx v0.1.
|
|
1
|
+
/*! rnx v0.1.716 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
|
|
2
2
|
let __sootsim_import_meta_url = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; } catch {}
|
|
3
3
|
"use strict";
|
|
4
4
|
var __create = Object.create;
|
|
@@ -21360,7 +21360,15 @@ var init_swift_icu = __esm({
|
|
|
21360
21360
|
});
|
|
21361
21361
|
|
|
21362
21362
|
// src/swift-package.ts
|
|
21363
|
-
function
|
|
21363
|
+
function swiftImplicitResourcePaths(paths) {
|
|
21364
|
+
return paths.filter(
|
|
21365
|
+
(file) => !file.endsWith(".swift") && (/\.(xcassets|xcstrings|nib|xib|storyboard|xcdatamodeld|xcdatamodel|xcmappingmodel|metal|xcprivacy)(?:\/|$)/.test(
|
|
21366
|
+
file
|
|
21367
|
+
) || /(?:^|\/)[^/]+\.lproj\/[^/]+$/.test(file))
|
|
21368
|
+
).sort();
|
|
21369
|
+
}
|
|
21370
|
+
function swiftManifestTargets(manifest, resourcePaths = []) {
|
|
21371
|
+
const implicitResources = swiftImplicitResourcePaths(resourcePaths);
|
|
21364
21372
|
const code = manifest.replace(/\/\*[\s\S]*?\*\//g, "").replace(/\/\/[^\n]*/g, "");
|
|
21365
21373
|
const targets = [];
|
|
21366
21374
|
const pattern = /\.(executableTarget|target)\s*\(/g;
|
|
@@ -21403,7 +21411,19 @@ function swiftManifestTargets(manifest) {
|
|
|
21403
21411
|
/\.swiftLanguageMode\(\s*\.v(\d+)\s*\)/.exec(call)?.[1] ?? "5"
|
|
21404
21412
|
);
|
|
21405
21413
|
const mainActorIsolation = /\.defaultIsolation\(\s*MainActor\.self\s*\)/.test(call);
|
|
21406
|
-
const
|
|
21414
|
+
const excluded = [
|
|
21415
|
+
...(/\bexclude\s*:\s*\[([^\]]*)\]/.exec(flat)?.[1] ?? "").matchAll(/"([^"]+)"/g)
|
|
21416
|
+
].map((match2) => match2[1].replace(/^\.\//, "").replace(/\/+$/, ""));
|
|
21417
|
+
const prefix = targetPath === "." ? "" : `${targetPath}/`;
|
|
21418
|
+
const resources = /\bresources\s*:/.test(flat) || implicitResources.some((file) => {
|
|
21419
|
+
if (!file.startsWith(prefix)) return false;
|
|
21420
|
+
const relative2 = file.slice(prefix.length);
|
|
21421
|
+
if (excluded.some(
|
|
21422
|
+
(exclude) => relative2 === exclude || relative2.startsWith(`${exclude}/`)
|
|
21423
|
+
))
|
|
21424
|
+
return false;
|
|
21425
|
+
return true;
|
|
21426
|
+
});
|
|
21407
21427
|
targets.push({
|
|
21408
21428
|
name: name2,
|
|
21409
21429
|
path: targetPath,
|
|
@@ -21415,8 +21435,8 @@ function swiftManifestTargets(manifest) {
|
|
|
21415
21435
|
}
|
|
21416
21436
|
return targets;
|
|
21417
21437
|
}
|
|
21418
|
-
function swiftPackagePartition(manifest) {
|
|
21419
|
-
const targets = swiftManifestTargets(manifest);
|
|
21438
|
+
function swiftPackagePartition(manifest, resourcePaths = []) {
|
|
21439
|
+
const targets = swiftManifestTargets(manifest, resourcePaths);
|
|
21420
21440
|
return targets.length === 1 && targets[0].executable && targets[0].path === "." ? [] : targets;
|
|
21421
21441
|
}
|
|
21422
21442
|
var init_swift_package = __esm({
|
|
@@ -21513,7 +21533,7 @@ function swiftModuleDigest(root) {
|
|
|
21513
21533
|
}
|
|
21514
21534
|
function compileTargets(input) {
|
|
21515
21535
|
const manifest = input.files["Package.swift"];
|
|
21516
|
-
return manifest === void 0 ? [] : swiftPackagePartition(manifest);
|
|
21536
|
+
return manifest === void 0 ? [] : swiftPackagePartition(manifest, input.resourcePaths);
|
|
21517
21537
|
}
|
|
21518
21538
|
function withNativeSourceGlue(input, glue) {
|
|
21519
21539
|
const targets = compileTargets(input);
|
|
@@ -21554,7 +21574,7 @@ function swiftTargetDependencies(files, targets) {
|
|
|
21554
21574
|
}
|
|
21555
21575
|
function swiftArtifactHash(input, release, moduleRoot) {
|
|
21556
21576
|
const hash = (0, import_node_crypto3.createHash)("sha256");
|
|
21557
|
-
hash.update(`swift-compile/
|
|
21577
|
+
hash.update(`swift-compile/v13
|
|
21558
21578
|
${release}
|
|
21559
21579
|
`);
|
|
21560
21580
|
if (input.oneModule) hash.update("one-module\n");
|
|
@@ -21576,6 +21596,10 @@ ${release}
|
|
|
21576
21596
|
hash.update((0, import_node_crypto3.createHash)("sha256").update(image.file).digest());
|
|
21577
21597
|
hash.update((0, import_node_crypto3.createHash)("sha256").update(image.data).digest());
|
|
21578
21598
|
}
|
|
21599
|
+
for (const file of [...new Set(input.resourcePaths ?? [])].sort()) {
|
|
21600
|
+
hash.update("resource-path\n");
|
|
21601
|
+
hash.update((0, import_node_crypto3.createHash)("sha256").update(file).digest());
|
|
21602
|
+
}
|
|
21579
21603
|
const targets = compileTargets(input);
|
|
21580
21604
|
if (targets.length > 0) {
|
|
21581
21605
|
hash.update(`swift-multi/v${MULTI_MANIFEST_VERSION}
|
|
@@ -22006,6 +22030,10 @@ function swiftCodeScan(source) {
|
|
|
22006
22030
|
return { lineStarts: starts, tokens };
|
|
22007
22031
|
}
|
|
22008
22032
|
function writeSwiftProject(layout, input, moduleRoot) {
|
|
22033
|
+
const resourceTargets = swiftManifestTargets(
|
|
22034
|
+
input.files["Package.swift"] ?? "",
|
|
22035
|
+
input.resourcePaths
|
|
22036
|
+
);
|
|
22009
22037
|
const distribution = swiftDistributionAt(moduleRoot);
|
|
22010
22038
|
const targets = distribution && compileTargets(input).length === 0 ? [
|
|
22011
22039
|
{
|
|
@@ -22024,8 +22052,14 @@ function writeSwiftProject(layout, input, moduleRoot) {
|
|
|
22024
22052
|
if (!distribution) {
|
|
22025
22053
|
modulePlan.update((0, import_node_fs7.readFileSync)(import_node_path7.default.join(moduleRoot, "Package.swift")));
|
|
22026
22054
|
}
|
|
22055
|
+
const resourcePlan = (0, import_node_crypto3.createHash)("sha256").update(
|
|
22056
|
+
JSON.stringify(
|
|
22057
|
+
resourceTargets.filter((target) => target.resources).map((target) => [target.name, target.path])
|
|
22058
|
+
)
|
|
22059
|
+
).digest("hex").slice(0, 16);
|
|
22027
22060
|
const moduleFiles = `
|
|
22028
22061
|
// sootsim-swift files ${modulePlan.digest("hex").slice(0, 16)}
|
|
22062
|
+
// resource accessors ${resourcePlan}
|
|
22029
22063
|
`;
|
|
22030
22064
|
if (targets.length === 0) {
|
|
22031
22065
|
for (const [file, contents] of Object.entries(input.files)) {
|
|
@@ -22078,20 +22112,6 @@ function writeSwiftProject(layout, input, moduleRoot) {
|
|
|
22078
22112
|
if (file === "Package.swift") continue;
|
|
22079
22113
|
files.set(import_node_path7.default.join(base, file), compiledSource(file, contents));
|
|
22080
22114
|
}
|
|
22081
|
-
for (const target of targets) {
|
|
22082
|
-
if (!target.resources) continue;
|
|
22083
|
-
files.set(
|
|
22084
|
-
import_node_path7.default.join(layout.root, target.path, "ResourceBundleAccessor.generated.swift"),
|
|
22085
|
-
[
|
|
22086
|
-
"import Foundation",
|
|
22087
|
-
"",
|
|
22088
|
-
"extension Foundation.Bundle {",
|
|
22089
|
-
" static let module: Bundle = Bundle.main",
|
|
22090
|
-
"}",
|
|
22091
|
-
""
|
|
22092
|
-
].join("\n")
|
|
22093
|
-
);
|
|
22094
|
-
}
|
|
22095
22115
|
files.set(
|
|
22096
22116
|
import_node_path7.default.join(layout.root, "Package.swift"),
|
|
22097
22117
|
emitSwiftPackageManifest({
|
|
@@ -22107,6 +22127,21 @@ function writeSwiftProject(layout, input, moduleRoot) {
|
|
|
22107
22127
|
}) + moduleFiles
|
|
22108
22128
|
);
|
|
22109
22129
|
}
|
|
22130
|
+
for (const target of resourceTargets) {
|
|
22131
|
+
if (!target.resources) continue;
|
|
22132
|
+
const directory = layout.multi ? import_node_path7.default.join(layout.root, target.path) : layout.sources;
|
|
22133
|
+
files.set(
|
|
22134
|
+
import_node_path7.default.join(directory, "ResourceBundleAccessor.generated.swift"),
|
|
22135
|
+
[
|
|
22136
|
+
"import Foundation",
|
|
22137
|
+
"",
|
|
22138
|
+
"extension Foundation.Bundle {",
|
|
22139
|
+
" static let module: Bundle = Bundle.main",
|
|
22140
|
+
"}",
|
|
22141
|
+
""
|
|
22142
|
+
].join("\n")
|
|
22143
|
+
);
|
|
22144
|
+
}
|
|
22110
22145
|
syncSwiftTree(layout.root, files);
|
|
22111
22146
|
}
|
|
22112
22147
|
function streamText(value) {
|
|
@@ -23832,6 +23867,11 @@ function packageSnapshot(project) {
|
|
|
23832
23867
|
const native = nativeSourceDescriptor(project.packagePath);
|
|
23833
23868
|
return {
|
|
23834
23869
|
files,
|
|
23870
|
+
resourcePaths: swiftImplicitResourcePaths(
|
|
23871
|
+
resourceCandidateFiles(project.packagePath).map(
|
|
23872
|
+
(file) => import_node_path13.default.relative(project.packagePath, file).split(import_node_path13.default.sep).join(import_node_path13.default.posix.sep)
|
|
23873
|
+
)
|
|
23874
|
+
),
|
|
23835
23875
|
resources: buildSwiftResourceTable(project, ""),
|
|
23836
23876
|
bundleFiles: buildSwiftBundleFiles(project.packagePath),
|
|
23837
23877
|
native,
|
|
@@ -23847,6 +23887,7 @@ function packageSnapshot(project) {
|
|
|
23847
23887
|
function snapshotCompileInput(snapshot, entry) {
|
|
23848
23888
|
const input = {
|
|
23849
23889
|
files: snapshot.files,
|
|
23890
|
+
resourcePaths: snapshot.resourcePaths,
|
|
23850
23891
|
resources: snapshot.bundleFiles.files,
|
|
23851
23892
|
images: snapshot.resources.images,
|
|
23852
23893
|
entry,
|
|
@@ -23922,6 +23963,7 @@ async function compileRemote(packagePath, entry, snapshot, hosted) {
|
|
|
23922
23963
|
submit,
|
|
23923
23964
|
{
|
|
23924
23965
|
files: snapshot.files,
|
|
23966
|
+
resourcePaths: snapshot.resourcePaths,
|
|
23925
23967
|
resources: snapshot.bundleFiles.files,
|
|
23926
23968
|
images: snapshot.resources.images,
|
|
23927
23969
|
entry,
|
|
@@ -24062,6 +24104,7 @@ var init_swift_host = __esm({
|
|
|
24062
24104
|
init_backend_origin();
|
|
24063
24105
|
init_swift_compile();
|
|
24064
24106
|
init_swift_distribution();
|
|
24107
|
+
init_swift_package();
|
|
24065
24108
|
init_swift_submit();
|
|
24066
24109
|
ARTIFACT_PATH = "/__peach/swift/";
|
|
24067
24110
|
RESOURCE_PATH = "/__peach/swift-res/";
|
|
@@ -28350,7 +28393,8 @@ var init_devices = __esm({
|
|
|
28350
28393
|
width: 402,
|
|
28351
28394
|
height: 874,
|
|
28352
28395
|
scale: 3,
|
|
28353
|
-
|
|
28396
|
+
// 62, the 17 pro's measured top: the same 402x874 panel and island.
|
|
28397
|
+
statusBarHeight: 62,
|
|
28354
28398
|
landscapeStatusBarHeight: 0,
|
|
28355
28399
|
homeIndicatorHeight: 34,
|
|
28356
28400
|
cornerRadius: cornerRadii(61),
|
|
@@ -28359,7 +28403,7 @@ var init_devices = __esm({
|
|
|
28359
28403
|
frameInsets: uniformFrameInsets(15.3),
|
|
28360
28404
|
dynamicIsland: { width: 125, height: 110 / 3, top: 14 },
|
|
28361
28405
|
statusRowCenter: 32.65,
|
|
28362
|
-
safeAreaInsets: { top:
|
|
28406
|
+
safeAreaInsets: { top: 62, bottom: 34, left: 0, right: 0 },
|
|
28363
28407
|
iosVersion: "27.0",
|
|
28364
28408
|
keyboardPanelHeights: { qwerty: 301, pad: 301, emoji: 395 },
|
|
28365
28409
|
physicalPPI: 460,
|
|
@@ -28379,7 +28423,10 @@ var init_devices = __esm({
|
|
|
28379
28423
|
width: 420,
|
|
28380
28424
|
height: 912,
|
|
28381
28425
|
scale: 3,
|
|
28382
|
-
|
|
28426
|
+
// 68: the island and status row sit 6pt lower than the 17 pro's, and the
|
|
28427
|
+
// simulator reports a 68pt top safe area (useyourloaf, iphone 17 screen
|
|
28428
|
+
// sizes), so a navigation bar starts 9pt lower than it did at 59.
|
|
28429
|
+
statusBarHeight: 68,
|
|
28383
28430
|
landscapeStatusBarHeight: 0,
|
|
28384
28431
|
homeIndicatorHeight: 34,
|
|
28385
28432
|
cornerRadius: cornerRadii(64.6),
|
|
@@ -28402,7 +28449,7 @@ var init_devices = __esm({
|
|
|
28402
28449
|
frameInsets: uniformFrameInsets(10.7),
|
|
28403
28450
|
dynamicIsland: { width: 125, height: 110 / 3, top: 20 },
|
|
28404
28451
|
statusRowCenter: 39,
|
|
28405
|
-
safeAreaInsets: { top:
|
|
28452
|
+
safeAreaInsets: { top: 68, bottom: 34, left: 0, right: 0 },
|
|
28406
28453
|
iosVersion: "27.0",
|
|
28407
28454
|
keyboardPanelHeights: { qwerty: 311, pad: 311, emoji: 405 },
|
|
28408
28455
|
physicalPPI: 460,
|
|
@@ -37214,13 +37261,17 @@ function findWindowsInstall() {
|
|
|
37214
37261
|
}
|
|
37215
37262
|
return null;
|
|
37216
37263
|
}
|
|
37217
|
-
function
|
|
37264
|
+
function getNativeDesktopAppPath() {
|
|
37218
37265
|
const explicitApp = process.env.PEACH_DESKTOP_APP;
|
|
37219
|
-
if (explicitApp)
|
|
37220
|
-
|
|
37221
|
-
|
|
37222
|
-
|
|
37223
|
-
|
|
37266
|
+
if (!explicitApp) return null;
|
|
37267
|
+
if (process.platform !== "darwin" || !explicitApp.endsWith(".app")) {
|
|
37268
|
+
throw new Error("PEACH_DESKTOP_APP must name a Mac .app bundle");
|
|
37269
|
+
}
|
|
37270
|
+
return (0, import_path5.resolve)(explicitApp);
|
|
37271
|
+
}
|
|
37272
|
+
function findDesktopCompanion() {
|
|
37273
|
+
const appPath = getNativeDesktopAppPath();
|
|
37274
|
+
if (appPath) {
|
|
37224
37275
|
if (!(0, import_fs6.existsSync)((0, import_path5.join)(appPath, "Contents/MacOS/PeachDesktop"))) {
|
|
37225
37276
|
throw new Error(`native desktop executable missing in ${appPath}`);
|
|
37226
37277
|
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! rnx v0.1.
|
|
1
|
+
/*! rnx v0.1.716 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
|
|
2
2
|
let __sootsim_import_meta_url = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; } catch {}
|
|
3
3
|
"use strict";
|
|
4
4
|
var __create = Object.create;
|
|
@@ -192,7 +192,15 @@ function icuSegment(object) {
|
|
|
192
192
|
}
|
|
193
193
|
|
|
194
194
|
// src/swift-package.ts
|
|
195
|
-
function
|
|
195
|
+
function swiftImplicitResourcePaths(paths) {
|
|
196
|
+
return paths.filter(
|
|
197
|
+
(file) => !file.endsWith(".swift") && (/\.(xcassets|xcstrings|nib|xib|storyboard|xcdatamodeld|xcdatamodel|xcmappingmodel|metal|xcprivacy)(?:\/|$)/.test(
|
|
198
|
+
file
|
|
199
|
+
) || /(?:^|\/)[^/]+\.lproj\/[^/]+$/.test(file))
|
|
200
|
+
).sort();
|
|
201
|
+
}
|
|
202
|
+
function swiftManifestTargets(manifest, resourcePaths = []) {
|
|
203
|
+
const implicitResources = swiftImplicitResourcePaths(resourcePaths);
|
|
196
204
|
const code = manifest.replace(/\/\*[\s\S]*?\*\//g, "").replace(/\/\/[^\n]*/g, "");
|
|
197
205
|
const targets = [];
|
|
198
206
|
const pattern = /\.(executableTarget|target)\s*\(/g;
|
|
@@ -235,7 +243,19 @@ function swiftManifestTargets(manifest) {
|
|
|
235
243
|
/\.swiftLanguageMode\(\s*\.v(\d+)\s*\)/.exec(call)?.[1] ?? "5"
|
|
236
244
|
);
|
|
237
245
|
const mainActorIsolation = /\.defaultIsolation\(\s*MainActor\.self\s*\)/.test(call);
|
|
238
|
-
const
|
|
246
|
+
const excluded = [
|
|
247
|
+
...(/\bexclude\s*:\s*\[([^\]]*)\]/.exec(flat)?.[1] ?? "").matchAll(/"([^"]+)"/g)
|
|
248
|
+
].map((match2) => match2[1].replace(/^\.\//, "").replace(/\/+$/, ""));
|
|
249
|
+
const prefix = targetPath === "." ? "" : `${targetPath}/`;
|
|
250
|
+
const resources = /\bresources\s*:/.test(flat) || implicitResources.some((file) => {
|
|
251
|
+
if (!file.startsWith(prefix)) return false;
|
|
252
|
+
const relative = file.slice(prefix.length);
|
|
253
|
+
if (excluded.some(
|
|
254
|
+
(exclude) => relative === exclude || relative.startsWith(`${exclude}/`)
|
|
255
|
+
))
|
|
256
|
+
return false;
|
|
257
|
+
return true;
|
|
258
|
+
});
|
|
239
259
|
targets.push({
|
|
240
260
|
name,
|
|
241
261
|
path: targetPath,
|
|
@@ -247,8 +267,8 @@ function swiftManifestTargets(manifest) {
|
|
|
247
267
|
}
|
|
248
268
|
return targets;
|
|
249
269
|
}
|
|
250
|
-
function swiftPackagePartition(manifest) {
|
|
251
|
-
const targets = swiftManifestTargets(manifest);
|
|
270
|
+
function swiftPackagePartition(manifest, resourcePaths = []) {
|
|
271
|
+
const targets = swiftManifestTargets(manifest, resourcePaths);
|
|
252
272
|
return targets.length === 1 && targets[0].executable && targets[0].path === "." ? [] : targets;
|
|
253
273
|
}
|
|
254
274
|
|
|
@@ -350,7 +370,7 @@ function swiftModuleDigest(root) {
|
|
|
350
370
|
}
|
|
351
371
|
function compileTargets(input) {
|
|
352
372
|
const manifest = input.files["Package.swift"];
|
|
353
|
-
return manifest === void 0 ? [] : swiftPackagePartition(manifest);
|
|
373
|
+
return manifest === void 0 ? [] : swiftPackagePartition(manifest, input.resourcePaths);
|
|
354
374
|
}
|
|
355
375
|
function withNativeSourceGlue(input, glue) {
|
|
356
376
|
const targets = compileTargets(input);
|
|
@@ -415,7 +435,7 @@ var ONE_IMPLICIT_FLAGS = ', "-Xfrontend", "-import-module", "-Xfrontend", "One"'
|
|
|
415
435
|
var MULTI_MANIFEST_VERSION = 10;
|
|
416
436
|
function swiftArtifactHash(input, release, moduleRoot) {
|
|
417
437
|
const hash = (0, import_node_crypto2.createHash)("sha256");
|
|
418
|
-
hash.update(`swift-compile/
|
|
438
|
+
hash.update(`swift-compile/v13
|
|
419
439
|
${release}
|
|
420
440
|
`);
|
|
421
441
|
if (input.oneModule) hash.update("one-module\n");
|
|
@@ -437,6 +457,10 @@ ${release}
|
|
|
437
457
|
hash.update((0, import_node_crypto2.createHash)("sha256").update(image.file).digest());
|
|
438
458
|
hash.update((0, import_node_crypto2.createHash)("sha256").update(image.data).digest());
|
|
439
459
|
}
|
|
460
|
+
for (const file of [...new Set(input.resourcePaths ?? [])].sort()) {
|
|
461
|
+
hash.update("resource-path\n");
|
|
462
|
+
hash.update((0, import_node_crypto2.createHash)("sha256").update(file).digest());
|
|
463
|
+
}
|
|
440
464
|
const targets = compileTargets(input);
|
|
441
465
|
if (targets.length > 0) {
|
|
442
466
|
hash.update(`swift-multi/v${MULTI_MANIFEST_VERSION}
|
|
@@ -905,6 +929,10 @@ function prepareSwiftDependency(source, destination) {
|
|
|
905
929
|
copy(source, destination, true);
|
|
906
930
|
}
|
|
907
931
|
function writeSwiftProject(layout, input, moduleRoot) {
|
|
932
|
+
const resourceTargets = swiftManifestTargets(
|
|
933
|
+
input.files["Package.swift"] ?? "",
|
|
934
|
+
input.resourcePaths
|
|
935
|
+
);
|
|
908
936
|
const distribution = swiftDistributionAt(moduleRoot);
|
|
909
937
|
const targets = distribution && compileTargets(input).length === 0 ? [
|
|
910
938
|
{
|
|
@@ -923,8 +951,14 @@ function writeSwiftProject(layout, input, moduleRoot) {
|
|
|
923
951
|
if (!distribution) {
|
|
924
952
|
modulePlan.update((0, import_node_fs2.readFileSync)(import_node_path2.default.join(moduleRoot, "Package.swift")));
|
|
925
953
|
}
|
|
954
|
+
const resourcePlan = (0, import_node_crypto2.createHash)("sha256").update(
|
|
955
|
+
JSON.stringify(
|
|
956
|
+
resourceTargets.filter((target) => target.resources).map((target) => [target.name, target.path])
|
|
957
|
+
)
|
|
958
|
+
).digest("hex").slice(0, 16);
|
|
926
959
|
const moduleFiles = `
|
|
927
960
|
// sootsim-swift files ${modulePlan.digest("hex").slice(0, 16)}
|
|
961
|
+
// resource accessors ${resourcePlan}
|
|
928
962
|
`;
|
|
929
963
|
if (targets.length === 0) {
|
|
930
964
|
for (const [file, contents] of Object.entries(input.files)) {
|
|
@@ -977,20 +1011,6 @@ function writeSwiftProject(layout, input, moduleRoot) {
|
|
|
977
1011
|
if (file === "Package.swift") continue;
|
|
978
1012
|
files.set(import_node_path2.default.join(base, file), compiledSource(file, contents));
|
|
979
1013
|
}
|
|
980
|
-
for (const target of targets) {
|
|
981
|
-
if (!target.resources) continue;
|
|
982
|
-
files.set(
|
|
983
|
-
import_node_path2.default.join(layout.root, target.path, "ResourceBundleAccessor.generated.swift"),
|
|
984
|
-
[
|
|
985
|
-
"import Foundation",
|
|
986
|
-
"",
|
|
987
|
-
"extension Foundation.Bundle {",
|
|
988
|
-
" static let module: Bundle = Bundle.main",
|
|
989
|
-
"}",
|
|
990
|
-
""
|
|
991
|
-
].join("\n")
|
|
992
|
-
);
|
|
993
|
-
}
|
|
994
1014
|
files.set(
|
|
995
1015
|
import_node_path2.default.join(layout.root, "Package.swift"),
|
|
996
1016
|
emitSwiftPackageManifest({
|
|
@@ -1006,6 +1026,21 @@ function writeSwiftProject(layout, input, moduleRoot) {
|
|
|
1006
1026
|
}) + moduleFiles
|
|
1007
1027
|
);
|
|
1008
1028
|
}
|
|
1029
|
+
for (const target of resourceTargets) {
|
|
1030
|
+
if (!target.resources) continue;
|
|
1031
|
+
const directory = layout.multi ? import_node_path2.default.join(layout.root, target.path) : layout.sources;
|
|
1032
|
+
files.set(
|
|
1033
|
+
import_node_path2.default.join(directory, "ResourceBundleAccessor.generated.swift"),
|
|
1034
|
+
[
|
|
1035
|
+
"import Foundation",
|
|
1036
|
+
"",
|
|
1037
|
+
"extension Foundation.Bundle {",
|
|
1038
|
+
" static let module: Bundle = Bundle.main",
|
|
1039
|
+
"}",
|
|
1040
|
+
""
|
|
1041
|
+
].join("\n")
|
|
1042
|
+
);
|
|
1043
|
+
}
|
|
1009
1044
|
syncSwiftTree(layout.root, files);
|
|
1010
1045
|
}
|
|
1011
1046
|
function streamText(value) {
|