peachsim 0.1.1841 → 0.1.1843
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/detox/index.ts +32 -0
- package/dist-lib/agent-daemon-client.cjs +1 -1
- package/dist-lib/agent-events.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/bundle-channel.cjs +25 -4
- package/dist-lib/capture-contract.cjs +1 -1
- package/dist-lib/capture-contract.mjs +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/config.mjs +1 -1
- package/dist-lib/detox/index.cjs +28 -1
- package/dist-lib/dev-bundle-resolution.cjs +1 -1
- package/dist-lib/expo-swift-bundle.cjs +23 -2
- package/dist-lib/expo-swift-metadata.cjs +1 -1
- package/dist-lib/expo-swift-metadata.mjs +1 -1
- package/dist-lib/home-paths.cjs +1 -1
- package/dist-lib/host/bridge-host.cjs +24 -3
- 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-project.cjs +1 -1
- package/dist-lib/native-app-identity-project.mjs +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/pdfium-raster.cjs +1 -1
- package/dist-lib/pdfium-raster.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/public-origins-lib-esm.json +24 -24
- package/dist-lib/public-origins-lib.json +53 -53
- package/dist-lib/react-native-host-modules.cjs +1 -1
- package/dist-lib/react-native-host-modules.mjs +1 -1
- package/dist-lib/reap-browser.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 +25 -4
- package/dist-lib/swift-compile.cjs +1 -1
- package/dist-lib/swift-compile.mjs +1 -1
- package/dist-lib/swift-package.cjs +1 -1
- package/dist-lib/swift-package.mjs +1 -1
- 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 +1 -1
- package/dist-lib/vite.cjs +1 -1
- package/dist-lib/worklet-executable.cjs +1 -1
- package/dist-lib/worklet-executable.mjs +1 -1
- package/package.json +1 -1
- package/src/expo-native-workspace.ts +40 -1
|
@@ -70,6 +70,8 @@ const NATIVE_CONFIG_FILE =
|
|
|
70
70
|
// native sources steer pod install by existing, not by content: an edit to one
|
|
71
71
|
// is copied into the prepared workspace, an added or removed one rebuilds it.
|
|
72
72
|
const NATIVE_SOURCE_FILE = /\.(swift|mm?|hpp?|c|cc|cpp|kt|java)$/
|
|
73
|
+
const NATIVE_PACKAGE_ENTRY =
|
|
74
|
+
/^(ios|android|.*\.podspec|expo-module\.config\.json|react-native\.config\.[cm]?[jt]s|app\.plugin\.[cm]?js)$/
|
|
73
75
|
|
|
74
76
|
// every file the native prepare can read, plus the toolchain that reads it.
|
|
75
77
|
// node_modules stays out: the js install reconciles it with the hashed
|
|
@@ -195,6 +197,42 @@ async function hashWorkspaceInputs(
|
|
|
195
197
|
const hash = createHash('sha256')
|
|
196
198
|
const native = createHash('sha256')
|
|
197
199
|
const nativeDirectories = localPackageDirectories(root, app)
|
|
200
|
+
// a local package that builds no native code does not steer the prepare by
|
|
201
|
+
// its own version, so a release bump of it and of its lockfile entry keeps
|
|
202
|
+
// the prepared workspace. the app keeps its version: expo config reads it.
|
|
203
|
+
const versionFree = new Set(
|
|
204
|
+
nativeDirectories
|
|
205
|
+
.filter((directory) => directory !== appRelative && directory !== '')
|
|
206
|
+
.filter(
|
|
207
|
+
(directory) =>
|
|
208
|
+
!fs
|
|
209
|
+
.readdirSync(path.join(root, directory))
|
|
210
|
+
.some((name) => NATIVE_PACKAGE_ENTRY.test(name)),
|
|
211
|
+
)
|
|
212
|
+
.map((directory) => directory.split(path.sep).join('/')),
|
|
213
|
+
)
|
|
214
|
+
const nativeConfigBytes = (posix: string, bytes: Buffer) => {
|
|
215
|
+
const directory = path.posix.dirname(posix)
|
|
216
|
+
if (path.posix.basename(posix) === 'package.json' && versionFree.has(directory)) {
|
|
217
|
+
const { version: _version, ...manifest } = JSON.parse(bytes.toString('utf8'))
|
|
218
|
+
return JSON.stringify(manifest)
|
|
219
|
+
}
|
|
220
|
+
if (posix !== 'bun.lock') return bytes
|
|
221
|
+
let entry: string | null = null
|
|
222
|
+
return bytes
|
|
223
|
+
.toString('utf8')
|
|
224
|
+
.split('\n')
|
|
225
|
+
.filter((line) => {
|
|
226
|
+
const opened = /^ {4}"([^"]+)": \{$/.exec(line)
|
|
227
|
+
if (opened) entry = opened[1] ?? null
|
|
228
|
+
return !(
|
|
229
|
+
entry &&
|
|
230
|
+
versionFree.has(entry) &&
|
|
231
|
+
/^ {6}"version": "[^"]*",$/.test(line)
|
|
232
|
+
)
|
|
233
|
+
})
|
|
234
|
+
.join('\n')
|
|
235
|
+
}
|
|
198
236
|
const steersNative = (relative: string) =>
|
|
199
237
|
!relative.includes(path.sep) ||
|
|
200
238
|
relative.startsWith(`patches${path.sep}`) ||
|
|
@@ -221,7 +259,8 @@ async function hashWorkspaceInputs(
|
|
|
221
259
|
if (NATIVE_CONFIG_FILE.test(posix)) {
|
|
222
260
|
const bytes = await fs.promises.readFile(file)
|
|
223
261
|
if (everyByte) hash.update(`file\0${bytes.length}\0`).update(bytes)
|
|
224
|
-
if (steersNative(relative))
|
|
262
|
+
if (steersNative(relative))
|
|
263
|
+
native.update(`${posix}\0`).update(nativeConfigBytes(posix, bytes))
|
|
225
264
|
} else {
|
|
226
265
|
if (everyByte) {
|
|
227
266
|
const bytes = await fs.promises.readFile(file)
|