@absolutejs/absolute 0.20.0-beta.130 → 0.20.0-beta.132
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 +28 -0
- package/changelog.json +52 -0
- package/dist/angular/browser.js +406 -396
- package/dist/angular/browser.js.map +4 -4
- package/dist/angular/components/core/streamingSlotRegistrar.js +1 -3
- package/dist/angular/components/core/streamingSlotRegistry.js +2 -4
- package/dist/angular/index.js +560 -701
- package/dist/angular/index.js.map +5 -5
- package/dist/angular/server.js +197 -338
- package/dist/angular/server.js.map +5 -5
- package/dist/build/buildWorker.js +27 -35
- package/dist/build.js +3833 -5876
- package/dist/build.js.map +4 -4
- package/dist/cli/{add-9sa7e3vd.js → add-hvqeg5sz.js} +23 -25
- package/dist/cli/{analyze-c1sep5y9.js → analyze-c2x2aym5.js} +6 -7
- package/dist/cli/androidEmulatorController-j73a1br6.js +22 -0
- package/dist/cli/{androidNativeWatcher-dnp95nk2.js → androidNativeWatcher-ctbnsr1v.js} +11 -14
- package/dist/cli/{api-2hd8cahp.js → api-rk13rfd9.js} +11 -13
- package/dist/cli/{build-857rc1ds.js → build-20y4b6rj.js} +8 -9
- package/dist/cli/{buildDepVendor-8akhr8n8.js → buildDepVendor-axqvbbm6.js} +5 -170
- package/dist/cli/{compile-9by2vxy5.js → compile-nf4qsqyd.js} +45 -48
- package/dist/cli/config/client.js +8 -8
- package/dist/cli/config/server.js +5615 -5595
- package/dist/cli/config-3te1fbry.js +7 -0
- package/dist/cli/{db-8wweexdp.js → db-p8pc325y.js} +5 -13
- package/dist/cli/{dev-qg7fr16s.js → dev-6f0gry3y.js} +75 -77
- package/dist/cli/{devCert-avr89zf3.js → devCert-n33ep8pg.js} +0 -3
- package/dist/cli/{doctor-mbh9bk05.js → doctor-8rm8p4dm.js} +13 -14
- package/dist/cli/emulatorDoctor-cwa70kgt.js +17 -0
- package/dist/cli/emulatorInstaller-dx3fmm2m.js +14 -0
- package/dist/cli/env-2107nff1.js +11 -0
- package/dist/cli/eslint-zz0t0kfp.js +17 -0
- package/dist/cli/eslintChunked-wg10jj9m.js +12 -0
- package/dist/cli/expoDevController-s70fj7vf.js +16 -0
- package/dist/cli/{expoNativeWatcher-rmc95bak.js → expoNativeWatcher-aakp7xvj.js} +1 -5
- package/dist/cli/expoProject-zy02tbfg.js +10 -0
- package/dist/cli/{generate-069p0dk3.js → generate-nz4w03yz.js} +19 -21
- package/dist/cli/{heapDiff-87v24x7p.js → heapDiff-2etr2r26.js} +5 -6
- package/dist/cli/{htmx-5wh1jh75.js → htmx-0xcaqrny.js} +12 -14
- package/dist/cli/{index-sjvydg2r.js → index-1ff9q1vx.js} +7 -7
- package/dist/cli/{index-rqbk0b30.js → index-1qewxkgy.js} +26 -26
- package/dist/cli/{index-prwyfnn3.js → index-1x1vah31.js} +2 -2
- package/dist/cli/{index-ddakkws4.js → index-31j3beht.js} +13 -13
- package/dist/cli/{index-j2nw3edf.js → index-3gtnqd57.js} +5 -5
- package/dist/cli/{index-54q7pxcx.js → index-434b7j4a.js} +2 -32
- package/dist/cli/{index-w5vswatm.js → index-43a1vvb7.js} +6 -10
- package/dist/cli/{index-nxcwg9ma.js → index-5sjk7daj.js} +31 -31
- package/dist/cli/{index-6j1xaheg.js → index-73sk1ney.js} +5 -5
- package/dist/cli/{index-3x5wpx5d.js → index-8kdmmgvc.js} +2 -2
- package/dist/cli/{index-1ys3dnrs.js → index-8w2wazrk.js} +34 -34
- package/dist/cli/{index-wtfnv3n2.js → index-92hmw204.js} +3 -3
- package/dist/cli/{index-vdbn8brx.js → index-c3tqbpkq.js} +40 -41
- package/dist/cli/{index-mywsk201.js → index-fde3c297.js} +1 -1
- package/dist/cli/{index-wctgx65x.js → index-hfvxsgf4.js} +48 -31
- package/dist/cli/{index-255xs63d.js → index-j57pgg5m.js} +10 -10
- package/dist/cli/{index-5cgsrv62.js → index-jcjwsdqt.js} +13 -182
- package/dist/cli/{index-00wfffav.js → index-k4t9k1xk.js} +5 -5
- package/dist/cli/{index-yxgaf8j0.js → index-m1vntzf1.js} +7 -5
- package/dist/cli/{index-9r7n9dqp.js → index-ma1dw7x2.js} +1 -1
- package/dist/cli/index-pch0v1z6.js +60 -0
- package/dist/cli/{index-8nym68py.js → index-ppxed116.js} +1 -1
- package/dist/cli/{index-9kwmb3c0.js → index-qyxd5n9a.js} +3 -3
- package/dist/cli/{index-tn4crd40.js → index-r62705dc.js} +12 -12
- package/dist/cli/{index-hty8111z.js → index-r915cvqp.js} +17 -17
- package/dist/cli/{index-exdd5k1g.js → index-rrxeqrbn.js} +2 -2
- package/dist/cli/{index-keg69zm1.js → index-snbzdwb9.js} +5 -5
- package/dist/cli/{index-v26ze17p.js → index-thqwfzy8.js} +3 -3
- package/dist/cli/{index-0hr7c4qe.js → index-vdnmqkt8.js} +14 -18
- package/dist/cli/{index-vkkqe08e.js → index-vj2v38sq.js} +29 -29
- package/dist/cli/{index-erngp7a9.js → index-wy0yh4jj.js} +16 -16
- package/dist/cli/{index-1cypb2zn.js → index-xcr3r6a1.js} +8 -8
- package/dist/cli/index.js +44 -48
- package/dist/cli/{info-d74dr585.js → info-kx5510rq.js} +7 -7
- package/dist/cli/{inspect-23chj4nc.js → inspect-5dj06x0m.js} +18 -20
- package/dist/cli/{iosNativeWatcher-kggp7j9a.js → iosNativeWatcher-zx49pzej.js} +12 -16
- package/dist/cli/iosSimulatorController-haa1cc3p.js +23 -0
- package/dist/cli/{islands-wpqgmwh0.js → islands-z4adh55n.js} +8 -9
- package/dist/cli/{lintProof-wx3b6dzy.js → lintProof-qcwdvzcz.js} +12 -17
- package/dist/cli/{logs-bx2n5ey6.js → logs-3p2vrq5h.js} +8 -10
- package/dist/cli/{ls-kvmcmd2j.js → ls-nkspq73y.js} +13 -14
- package/dist/cli/{mem-apbk7bx4.js → mem-h3f497cr.js} +10 -14
- package/dist/cli/{migrate-p4rp5r6b.js → migrate-52bqqp08.js} +7 -8
- package/dist/cli/{mobile-43q3zmjf.js → mobile-m0cdh8cf.js} +572 -575
- package/dist/cli/nativeAuth-ysv0x5dy.js +27 -0
- package/dist/cli/patchedBun-m7vj5sks.js +9 -0
- package/dist/cli/prerender-mfnwsvyt.js +7 -0
- package/dist/cli/{prettier-vtk5yaw4.js → prettier-c1624g36.js} +2 -6
- package/dist/cli/{ps-8y28kzmb.js → ps-0jedm91n.js} +12 -16
- package/dist/cli/{psTui-8e96mwgz.js → psTui-tpr5nbmc.js} +28 -30
- package/dist/cli/remoteMacProtocol-v3ax0y0f.js +41 -0
- package/dist/cli/{remove-3fd1z2hx.js → remove-z0brj5nd.js} +16 -18
- package/dist/cli/{rewriteImports-d1gmaa68.js → rewriteImports-k6rjjmg1.js} +2 -100
- package/dist/cli/{routes-0xpanj8z.js → routes-ey0sw1eq.js} +7 -9
- package/dist/cli/start-3z3gtgm0.js +20 -0
- package/dist/cli/telemetry-3wnc06wa.js +9 -0
- package/dist/cli/{tunnelRelay-5at2v8w6.js → tunnelRelay-19ay0fxn.js} +3 -4
- package/dist/cli/{typecheck-yj9s13eb.js → typecheck-nmf6e7k7.js} +147 -149
- package/dist/cli/{workspace-m56sgfkc.js → workspace-yetzedke.js} +32 -36
- package/dist/client/chunks/{index-dk743xs6.js → index-8m2qq61n.js} +12 -8
- package/dist/client/chunks/{index-dk743xs6.js.map → index-8m2qq61n.js.map} +4 -3
- package/dist/client/chunks/{index-m35nbkdp.js → islands-rc28k5sx.js} +104 -42
- package/dist/client/chunks/islands-rc28k5sx.js.map +15 -0
- package/dist/client/chunks/{react-yq4ss9y4.js → react-dcvkaba2.js} +5 -7
- package/dist/client/chunks/{react-yq4ss9y4.js.map → react-dcvkaba2.js.map} +2 -2
- package/dist/client/chunks/{svelte-s0c964kb.js → svelte-4yfa5bxa.js} +2 -4
- package/dist/client/chunks/{svelte-s0c964kb.js.map → svelte-4yfa5bxa.js.map} +2 -2
- package/dist/client/chunks/{vue-rdskrnyg.js → vue-a84fzp3v.js} +2 -4
- package/dist/client/chunks/{vue-rdskrnyg.js.map → vue-a84fzp3v.js.map} +2 -2
- package/dist/client/index.js +42 -15
- package/dist/client/index.js.map +2 -2
- package/dist/client/prefetch.js +1 -3
- package/dist/client/prefetch.js.map +2 -2
- package/dist/core/streamingSlotRegistrar.js +1 -64
- package/dist/core/streamingSlotRegistrar.js.map +2 -2
- package/dist/core/streamingSlotRegistry.js +1 -64
- package/dist/core/streamingSlotRegistry.js.map +2 -2
- package/dist/dev/serverBootstrap.js +1802 -2018
- package/dist/index.js +5247 -8794
- package/dist/index.js.map +9 -20
- package/dist/islands/browser.js +13 -3
- package/dist/islands/browser.js.map +2 -2
- package/dist/islands/index.js +26 -142
- package/dist/islands/index.js.map +2 -2
- package/dist/mobile/browser.js +13 -3
- package/dist/mobile/browser.js.map +2 -2
- package/dist/mobile/index.js +1067 -2182
- package/dist/mobile/index.js.map +2 -2
- package/dist/mobile/remoteMacAgentEntry.js +156 -156
- package/dist/mobile/shellAuth.js +0 -16
- package/dist/mobile/shellBootstrap.js +734 -724
- package/dist/mobile/shellExpoAuth.js +4 -18
- package/dist/mobile/shellExpoDevices.js +0 -16
- package/dist/mobile/shellExpoSync.js +0 -16
- package/dist/mobile/shellSync.js +3 -19
- package/dist/mobile/shellUpdate.js +5 -21
- package/dist/mobile/uiPrimitives.js +0 -16
- package/dist/react/browser.js +15 -5
- package/dist/react/browser.js.map +2 -2
- package/dist/react/components/index.js +68 -58
- package/dist/react/components/index.js.map +4 -4
- package/dist/react/hooks/index.js +1 -63
- package/dist/react/hooks/index.js.map +2 -2
- package/dist/react/index.js +56 -195
- package/dist/react/index.js.map +5 -5
- package/dist/react/jsxDevRuntimeCompat.js +1 -64
- package/dist/react/jsxDevRuntimeCompat.js.map +2 -2
- package/dist/react/jsxRuntimeCompat.js +1 -64
- package/dist/react/jsxRuntimeCompat.js.map +2 -2
- package/dist/react/router/browser.js +1 -64
- package/dist/react/router/browser.js.map +2 -2
- package/dist/react/router/index.js +1 -64
- package/dist/react/router/index.js.map +2 -2
- package/dist/react/server.js +38 -51
- package/dist/react/server.js.map +5 -5
- package/dist/src/cli/config/server.d.ts +7 -129
- package/dist/src/cli/patchedBun.d.ts +14 -14
- package/dist/src/cli/serverBundleExternals.d.ts +17 -2
- package/dist/src/core/prepare.d.ts +149 -1805
- package/dist/src/core/requestContext.d.ts +1 -1
- package/dist/src/dev/requestInspector.d.ts +1 -1
- package/dist/src/mobile/associationFiles.d.ts +2 -2
- package/dist/src/mobile/compatibilityDispatcher.d.ts +1 -1
- package/dist/src/mobile/mobilePreview.d.ts +8 -130
- package/dist/src/mobile/updateServer.d.ts +2 -2
- package/dist/src/plugins/devtoolsJson.d.ts +2 -2
- package/dist/src/plugins/hmr.d.ts +2 -2
- package/dist/src/plugins/imageOptimizer.d.ts +2 -151
- package/dist/src/plugins/telemetryPlugin.d.ts +1 -19
- package/dist/svelte/browser.js +13 -3
- package/dist/svelte/browser.js.map +2 -2
- package/dist/svelte/index.js +66 -210
- package/dist/svelte/index.js.map +5 -5
- package/dist/svelte/server.js +51 -99
- package/dist/svelte/server.js.map +5 -5
- package/dist/types/globals.d.ts +0 -6
- package/dist/vue/browser.js +13 -3
- package/dist/vue/browser.js.map +2 -2
- package/dist/vue/components/Image.js +13 -3
- package/dist/vue/components/Image.js.map +2 -2
- package/dist/vue/components/index.js +62 -50
- package/dist/vue/components/index.js.map +4 -4
- package/dist/vue/index.js +1115 -1258
- package/dist/vue/index.js.map +10 -10
- package/dist/vue/server.js +42 -59
- package/dist/vue/server.js.map +5 -5
- package/package.json +9 -9
- package/dist/cli/androidEmulatorController-sj141e1c.js +0 -30
- package/dist/cli/config-rjeexvza.js +0 -8
- package/dist/cli/emulatorDoctor-gzarrsex.js +0 -18
- package/dist/cli/emulatorInstaller-pjw4ex6q.js +0 -15
- package/dist/cli/env-4f6f6z69.js +0 -14
- package/dist/cli/eslint-qfkxe89p.js +0 -20
- package/dist/cli/eslintChunked-7ef700pn.js +0 -21
- package/dist/cli/expoDevController-weywa74d.js +0 -26
- package/dist/cli/expoProject-w2pzjwnx.js +0 -11
- package/dist/cli/index-1rabqyq0.js +0 -7
- package/dist/cli/index-ar4gz15x.js +0 -60
- package/dist/cli/iosSimulatorController-xcxxfkzx.js +0 -34
- package/dist/cli/nativeAuth-zx4tsb1f.js +0 -38
- package/dist/cli/patchedBun-zjtrn2s4.js +0 -38
- package/dist/cli/prerender-yex2zwj3.js +0 -18
- package/dist/cli/remoteMacProtocol-r38jhg44.js +0 -69
- package/dist/cli/start-gzhrkhxe.js +0 -23
- package/dist/cli/telemetry-94rka1w2.js +0 -14
- package/dist/client/chunks/angularPatch-arh4sr68.js +0 -157
- package/dist/client/chunks/angularPatch-arh4sr68.js.map +0 -10
- package/dist/client/chunks/index-jrcwp722.js +0 -12
- package/dist/client/chunks/index-jrcwp722.js.map +0 -10
- package/dist/client/chunks/index-m35nbkdp.js.map +0 -12
- package/dist/client/chunks/index-qxjc7kc5.js +0 -12
- package/dist/client/chunks/index-qxjc7kc5.js.map +0 -9
- package/dist/client/chunks/islands-50dg63j9.js +0 -284
- package/dist/client/chunks/islands-50dg63j9.js.map +0 -14
- /package/dist/cli/{index-me8nczrw.js → index-039rh39e.js} +0 -0
- /package/dist/cli/{index-bw4ktfnz.js → index-1y5mmnwg.js} +0 -0
- /package/dist/cli/{index-5xfxd7xa.js → index-3wm8p7rg.js} +0 -0
- /package/dist/cli/{index-4rme31py.js → index-420h9hq7.js} +0 -0
- /package/dist/cli/{index-4rhxthsy.js → index-65kqn88a.js} +0 -0
- /package/dist/cli/{index-r8x3839e.js → index-71gchbzt.js} +0 -0
- /package/dist/cli/{index-s2tazax7.js → index-92g14j47.js} +0 -0
- /package/dist/cli/{index-j66p8hn5.js → index-bwsa6ax4.js} +0 -0
- /package/dist/cli/{index-bzs19w3r.js → index-e6ysp900.js} +0 -0
- /package/dist/cli/{index-06cmrcdq.js → index-h7qhz02e.js} +0 -0
- /package/dist/cli/{index-6h54jqdq.js → index-hg54jyts.js} +0 -0
- /package/dist/cli/{index-czwrxgdj.js → index-hxqprc80.js} +0 -0
- /package/dist/cli/{index-zh6hhrwy.js → index-jjfbjv1z.js} +0 -0
- /package/dist/cli/{index-fc9vxw56.js → index-prs14ys9.js} +0 -0
- /package/dist/cli/{index-v1k46q3x.js → index-tx0kx9zx.js} +0 -0
- /package/dist/cli/{index-fhaf3tdk.js → index-x8x0f3ha.js} +0 -0
- /package/dist/cli/{index-18q9qc7f.js → index-ypcqx24p.js} +0 -0
|
@@ -1,16 +1,16 @@
|
|
|
1
1
|
// @bun
|
|
2
2
|
import {
|
|
3
|
-
|
|
4
|
-
|
|
3
|
+
ABSOLUTE_ANDROID_AVD_NAME2,
|
|
4
|
+
absoluteManagedAndroidSdkRoot2,
|
|
5
|
+
detectAbsoluteMobileHost2,
|
|
6
|
+
inspectAbsoluteMobileToolchain2
|
|
7
|
+
} from "./index-j57pgg5m.js";
|
|
5
8
|
import {
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
detectAbsoluteMobileHost,
|
|
9
|
-
inspectAbsoluteMobileToolchain
|
|
10
|
-
} from "./index-255xs63d.js";
|
|
9
|
+
writeAbsoluteCapacitorConfig
|
|
10
|
+
} from "./index-ypcqx24p.js";
|
|
11
11
|
import {
|
|
12
12
|
getDurationString
|
|
13
|
-
} from "./index-
|
|
13
|
+
} from "./index-1x1vah31.js";
|
|
14
14
|
|
|
15
15
|
// src/mobile/androidEmulatorController.ts
|
|
16
16
|
import {
|
|
@@ -358,7 +358,7 @@ var hashNativeTree = async (root, label, ignorePublicBundle) => {
|
|
|
358
358
|
const records = await collectNativeDirectory(resolvedRoot, label, resolvedRoot, ignorePublicBundle);
|
|
359
359
|
return createHash("sha256").update(records.join("")).digest("hex");
|
|
360
360
|
};
|
|
361
|
-
var
|
|
361
|
+
var fingerprintAbsoluteAndroidNativeProject2 = async (project, options = {}) => {
|
|
362
362
|
const { dependencies } = await nativeDependencySources(project.nativeDirectory);
|
|
363
363
|
const roots = [
|
|
364
364
|
{
|
|
@@ -410,7 +410,7 @@ var restoreAndroidProjectedFile = async (file) => {
|
|
|
410
410
|
await mkdir(dirname(file.path), { recursive: true });
|
|
411
411
|
await copyFile(file.backupPath, file.path);
|
|
412
412
|
};
|
|
413
|
-
var
|
|
413
|
+
var repairAbsoluteAndroidDevSession2 = async (projectRoot) => {
|
|
414
414
|
const paths = journalPaths(projectRoot);
|
|
415
415
|
if (!await pathExists(paths.journal)) {
|
|
416
416
|
await rm(paths.root, { force: true, recursive: true });
|
|
@@ -478,7 +478,7 @@ var withAndroidDebugCertificateAuthority = (source) => {
|
|
|
478
478
|
};
|
|
479
479
|
var writeDevConfig = async (projectRoot, nativeConfigPath, nativeManifestPath, port, https, entry, embeddedBundle, serverHost, certificateAuthorityPath) => {
|
|
480
480
|
const paths = journalPaths(projectRoot);
|
|
481
|
-
await
|
|
481
|
+
await repairAbsoluteAndroidDevSession2(projectRoot);
|
|
482
482
|
const source = await readFile(nativeConfigPath, "utf8");
|
|
483
483
|
const manifestSource = await readFile(nativeManifestPath, "utf8");
|
|
484
484
|
const parsed = JSON.parse(source);
|
|
@@ -541,22 +541,22 @@ var writeDevConfig = async (projectRoot, nativeConfigPath, nativeManifestPath, p
|
|
|
541
541
|
}
|
|
542
542
|
await writeFile(nativeManifestPath, androidDevelopmentManifest(manifestSource, !https, https && certificateAuthorityPath !== undefined ? networkConfigName : undefined));
|
|
543
543
|
};
|
|
544
|
-
var
|
|
544
|
+
var parseAdbDevices2 = (output) => output.split(/\r?\n/).slice(1).map((line) => line.trim().split(/\s+/, 2)).filter((parts) => parts.length === 2 && parts[1] === "device").map(([serial]) => serial);
|
|
545
545
|
var isManagedEmulatorSerial = (serial, adb, capture, env) => {
|
|
546
546
|
if (!serial.startsWith("emulator-"))
|
|
547
547
|
return false;
|
|
548
548
|
const avd = capture([adb, "-s", serial, "emu", "avd", "name"], { env });
|
|
549
|
-
return avd.exitCode === 0 && avd.stdout.split(/\r?\n/).map((value) => value.trim()).includes(
|
|
549
|
+
return avd.exitCode === 0 && avd.stdout.split(/\r?\n/).map((value) => value.trim()).includes(ABSOLUTE_ANDROID_AVD_NAME2);
|
|
550
550
|
};
|
|
551
551
|
var managedEmulatorSerial = (adb, capture, env) => {
|
|
552
552
|
const devices = capture([adb, "devices"], { env });
|
|
553
553
|
if (devices.exitCode !== 0)
|
|
554
554
|
return;
|
|
555
|
-
return
|
|
555
|
+
return parseAdbDevices2(devices.stdout).find((serial) => isManagedEmulatorSerial(serial, adb, capture, env));
|
|
556
556
|
};
|
|
557
557
|
var requireConnectedAndroidDevice = (adb, serial, capture, env) => {
|
|
558
558
|
const devices = capture([adb, "devices"], { env });
|
|
559
|
-
if (devices.exitCode !== 0 || !
|
|
559
|
+
if (devices.exitCode !== 0 || !parseAdbDevices2(devices.stdout).includes(serial)) {
|
|
560
560
|
throw new Error(`Android device ${serial} is not connected and authorized. Confirm the USB debugging prompt, then retry.`);
|
|
561
561
|
}
|
|
562
562
|
};
|
|
@@ -579,7 +579,7 @@ var waitForManagedEmulator = async (project, capture, sleep, env, signal, prefer
|
|
|
579
579
|
if (serial)
|
|
580
580
|
return serial;
|
|
581
581
|
if (Date.now() >= deadline) {
|
|
582
|
-
throw new Error(`Android ${preferredSerial ? `target ${preferredSerial}` : `emulator ${
|
|
582
|
+
throw new Error(`Android ${preferredSerial ? `target ${preferredSerial}` : `emulator ${ABSOLUTE_ANDROID_AVD_NAME2}`} did not finish booting within ${ANDROID_BOOT_TIMEOUT_MS / ANDROID_BOOT_POLL_MS}s.`);
|
|
583
583
|
}
|
|
584
584
|
await sleep(ANDROID_BOOT_POLL_MS);
|
|
585
585
|
return poll();
|
|
@@ -658,7 +658,7 @@ var resolveGradleArtifactPath = async (nativeDirectory, task) => {
|
|
|
658
658
|
}
|
|
659
659
|
return join(nativeDirectory, "app", "build", "outputs", "apk", "release", "app-release-unsigned.apk");
|
|
660
660
|
};
|
|
661
|
-
var
|
|
661
|
+
var buildAbsoluteAndroidGradleArtifact2 = async (options) => {
|
|
662
662
|
const { project, task } = options;
|
|
663
663
|
const capture = options.capture ?? captureCommand;
|
|
664
664
|
const run = options.run ?? runCommand;
|
|
@@ -677,10 +677,10 @@ var buildAbsoluteAndroidGradleArtifact = async (options) => {
|
|
|
677
677
|
"-EncodedCommand",
|
|
678
678
|
encodedWindowsGradleCommand(windowsSource, windowsDirectory, windowsAndroidRoot, dependencies, rewrittenSettings, task, gradleArguments)
|
|
679
679
|
], "Android Gradle build", run, { env, signal: options.signal });
|
|
680
|
-
const
|
|
681
|
-
const unsigned =
|
|
680
|
+
const artifactPath = await resolveGradleArtifactPath(managedBuildDirectory, task);
|
|
681
|
+
const unsigned = artifactPath.endsWith("-unsigned.apk");
|
|
682
682
|
return {
|
|
683
|
-
artifactPath
|
|
683
|
+
artifactPath,
|
|
684
684
|
installPath: unsigned ? win32.join(windowsDirectory, "app", "build", "outputs", "apk", "release", "app-release-unsigned.apk") : gradleArtifactPath(windowsDirectory, task, true)
|
|
685
685
|
};
|
|
686
686
|
}
|
|
@@ -689,7 +689,7 @@ var buildAbsoluteAndroidGradleArtifact = async (options) => {
|
|
|
689
689
|
const artifactPath = await resolveGradleArtifactPath(project.nativeDirectory, task);
|
|
690
690
|
return { artifactPath, installPath: artifactPath };
|
|
691
691
|
};
|
|
692
|
-
var buildAndroidDebugApp = async (project, capture, run, env, signal) => (await
|
|
692
|
+
var buildAndroidDebugApp = async (project, capture, run, env, signal) => (await buildAbsoluteAndroidGradleArtifact2({
|
|
693
693
|
capture,
|
|
694
694
|
env,
|
|
695
695
|
project,
|
|
@@ -761,11 +761,11 @@ var startManagedEmulatorIfNeeded = (project, capture, spawn, log, env) => {
|
|
|
761
761
|
const serial = managedEmulatorSerial(project.adb, capture, env);
|
|
762
762
|
if (serial)
|
|
763
763
|
return { serial, started: false };
|
|
764
|
-
log(`Starting Android emulator ${
|
|
764
|
+
log(`Starting Android emulator ${ABSOLUTE_ANDROID_AVD_NAME2}...`);
|
|
765
765
|
spawn([
|
|
766
766
|
project.emulator,
|
|
767
767
|
"-avd",
|
|
768
|
-
|
|
768
|
+
ABSOLUTE_ANDROID_AVD_NAME2,
|
|
769
769
|
"-netdelay",
|
|
770
770
|
"none",
|
|
771
771
|
"-netspeed",
|
|
@@ -878,11 +878,11 @@ var attachAndroidNativeLogs = (project, serial, capture, env, options, knownUid)
|
|
|
878
878
|
"chromium:I"
|
|
879
879
|
], { env }, onLine);
|
|
880
880
|
};
|
|
881
|
-
var
|
|
881
|
+
var prepareAbsoluteAndroidDevProject2 = async (config, options) => {
|
|
882
882
|
const projectRoot = resolve(options.projectRoot);
|
|
883
|
-
const host =
|
|
884
|
-
const androidRoot = process.env.ANDROID_HOME ?? process.env.ANDROID_SDK_ROOT ??
|
|
885
|
-
const checks = await
|
|
883
|
+
const host = detectAbsoluteMobileHost2();
|
|
884
|
+
const androidRoot = process.env.ANDROID_HOME ?? process.env.ANDROID_SDK_ROOT ?? absoluteManagedAndroidSdkRoot2(host);
|
|
885
|
+
const checks = await inspectAbsoluteMobileToolchain2({ androidRoot, host });
|
|
886
886
|
const deviceOnlyChecks = new Set([
|
|
887
887
|
"android.avd",
|
|
888
888
|
"android.avdmanager",
|
|
@@ -932,7 +932,7 @@ var prepareAbsoluteAndroidDevProject = async (config, options) => {
|
|
|
932
932
|
projectRoot
|
|
933
933
|
};
|
|
934
934
|
};
|
|
935
|
-
var
|
|
935
|
+
var startAbsoluteAndroidDevSession2 = async (options) => {
|
|
936
936
|
const { project } = options;
|
|
937
937
|
const startupStartedAt = performance.now();
|
|
938
938
|
let phaseStartedAt = performance.now();
|
|
@@ -966,7 +966,7 @@ var startAbsoluteAndroidDevSession = async (options) => {
|
|
|
966
966
|
ANDROID_HOME: androidHome
|
|
967
967
|
};
|
|
968
968
|
transition("syncing");
|
|
969
|
-
await
|
|
969
|
+
await repairAbsoluteAndroidDevSession2(project.projectRoot);
|
|
970
970
|
throwIfAborted(options.signal);
|
|
971
971
|
await requireSuccess([project.cap, "sync", "android"], "Capacitor Android synchronization", run, { cwd: project.projectRoot, env, signal: options.signal });
|
|
972
972
|
throwIfAborted(options.signal);
|
|
@@ -991,7 +991,7 @@ var startAbsoluteAndroidDevSession = async (options) => {
|
|
|
991
991
|
throwIfAborted(options.signal);
|
|
992
992
|
logHttpsCertificateRequirement(options.https, log);
|
|
993
993
|
const fingerprintStartedAt = performance.now();
|
|
994
|
-
const nativeFingerprintPromise =
|
|
994
|
+
const nativeFingerprintPromise = fingerprintAbsoluteAndroidNativeProject2(project, {
|
|
995
995
|
includePublicBundle: options.embeddedBundle === true
|
|
996
996
|
}).then((fingerprint) => {
|
|
997
997
|
phaseDurations.fingerprinting = performance.now() - fingerprintStartedAt;
|
|
@@ -1056,7 +1056,7 @@ var startAbsoluteAndroidDevSession = async (options) => {
|
|
|
1056
1056
|
await closeNativeLogs();
|
|
1057
1057
|
if (!physicalDevice)
|
|
1058
1058
|
await removeAdbReverse(project, serial, options.port, run, env);
|
|
1059
|
-
await
|
|
1059
|
+
await repairAbsoluteAndroidDevSession2(project.projectRoot);
|
|
1060
1060
|
transition("closed");
|
|
1061
1061
|
};
|
|
1062
1062
|
return {
|
|
@@ -1071,7 +1071,7 @@ var startAbsoluteAndroidDevSession = async (options) => {
|
|
|
1071
1071
|
}
|
|
1072
1072
|
log("Android native inputs changed; rebuilding without restarting the dev server.");
|
|
1073
1073
|
await close();
|
|
1074
|
-
return
|
|
1074
|
+
return startAbsoluteAndroidDevSession2(options);
|
|
1075
1075
|
},
|
|
1076
1076
|
relaunch: async () => {
|
|
1077
1077
|
if (closed) {
|
|
@@ -1096,9 +1096,9 @@ var startAbsoluteAndroidDevSession = async (options) => {
|
|
|
1096
1096
|
await closeNativeLogs();
|
|
1097
1097
|
if (!options.deviceSerial)
|
|
1098
1098
|
await removeAdbReverse(project, connectedSerial, options.port, run, env);
|
|
1099
|
-
await
|
|
1099
|
+
await repairAbsoluteAndroidDevSession2(project.projectRoot);
|
|
1100
1100
|
throw error;
|
|
1101
1101
|
}
|
|
1102
1102
|
};
|
|
1103
1103
|
|
|
1104
|
-
export {
|
|
1104
|
+
export { fingerprintAbsoluteAndroidNativeProject2, repairAbsoluteAndroidDevSession2, parseAdbDevices2, buildAbsoluteAndroidGradleArtifact2, prepareAbsoluteAndroidDevProject2, startAbsoluteAndroidDevSession2 };
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
// @bun
|
|
2
2
|
import {
|
|
3
3
|
HOURS_IN_HALF_DAY
|
|
4
|
-
} from "./index-
|
|
4
|
+
} from "./index-hxqprc80.js";
|
|
5
5
|
|
|
6
6
|
// src/utils/startupBanner.ts
|
|
7
7
|
var MONTHS = [
|
|
@@ -18,7 +18,7 @@ var MONTHS = [
|
|
|
18
18
|
"Nov",
|
|
19
19
|
"Dec"
|
|
20
20
|
];
|
|
21
|
-
var
|
|
21
|
+
var formatTimestamp2 = () => {
|
|
22
22
|
const now = new Date;
|
|
23
23
|
const month = MONTHS[now.getMonth()];
|
|
24
24
|
const day = now.getDate().toString().padStart(2, "0");
|
|
@@ -30,4 +30,4 @@ var formatTimestamp = () => {
|
|
|
30
30
|
return `${month} ${day} ${hours}:${minutes}:${seconds} ${ampm}`;
|
|
31
31
|
};
|
|
32
32
|
|
|
33
|
-
export {
|
|
33
|
+
export { formatTimestamp2 };
|
|
@@ -1,62 +1,60 @@
|
|
|
1
1
|
// @bun
|
|
2
2
|
import {
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
3
|
+
DEFAULT_PORT,
|
|
4
|
+
MAX_ERROR_LENGTH,
|
|
5
|
+
MILLISECONDS_IN_A_SECOND
|
|
6
|
+
} from "./index-hxqprc80.js";
|
|
7
|
+
import {
|
|
8
|
+
deregisterInstance,
|
|
9
|
+
registerInstance,
|
|
10
|
+
resolveProjectName
|
|
11
|
+
} from "./index-71gchbzt.js";
|
|
12
|
+
import {
|
|
13
|
+
loadIslandRegistryBuildInfo
|
|
14
|
+
} from "./index-e6ysp900.js";
|
|
15
|
+
import {
|
|
6
16
|
createIslandRegistryDefinitionPlugin,
|
|
17
|
+
createBunStringRawUnicodePlugin,
|
|
7
18
|
finalizeAbsoluteMobileCompatibilityBuild,
|
|
19
|
+
createAbsoluteMobileRouteMetadataPlugin,
|
|
20
|
+
createElysiaOpenApiTypeboxPlugin,
|
|
21
|
+
createOptionalPeerPlugin,
|
|
8
22
|
resolveServerBundleExternals
|
|
9
|
-
} from "./index-
|
|
23
|
+
} from "./index-hfvxsgf4.js";
|
|
10
24
|
import {
|
|
11
|
-
|
|
12
|
-
} from "./index-
|
|
13
|
-
import {
|
|
14
|
-
stripStringsAndComments
|
|
15
|
-
} from "./index-fc9vxw56.js";
|
|
25
|
+
normalizeAbsoluteMobileConfig2
|
|
26
|
+
} from "./index-rrxeqrbn.js";
|
|
16
27
|
import {
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
resolveProjectName
|
|
20
|
-
} from "./index-r8x3839e.js";
|
|
28
|
+
installAbsoluteMobileAuthEnvironment2
|
|
29
|
+
} from "./index-pch0v1z6.js";
|
|
21
30
|
import {
|
|
22
31
|
loadConfig
|
|
23
|
-
} from "./index-
|
|
24
|
-
import {
|
|
25
|
-
sendTelemetryEvent
|
|
26
|
-
} from "./index-9kwmb3c0.js";
|
|
32
|
+
} from "./index-h7qhz02e.js";
|
|
27
33
|
import {
|
|
28
|
-
|
|
29
|
-
} from "./index-
|
|
34
|
+
stripStringsAndComments
|
|
35
|
+
} from "./index-prs14ys9.js";
|
|
30
36
|
import {
|
|
31
|
-
|
|
32
|
-
} from "./index-
|
|
37
|
+
sendTelemetryEvent
|
|
38
|
+
} from "./index-qyxd5n9a.js";
|
|
33
39
|
import {
|
|
34
40
|
COMPOSE_PATH,
|
|
35
41
|
killStaleProcesses,
|
|
36
42
|
readDbScripts,
|
|
37
43
|
startDatabase,
|
|
38
44
|
stopDatabase
|
|
39
|
-
} from "./index-
|
|
45
|
+
} from "./index-k4t9k1xk.js";
|
|
40
46
|
import {
|
|
41
|
-
|
|
42
|
-
} from "./index-
|
|
47
|
+
formatTimestamp2
|
|
48
|
+
} from "./index-92hmw204.js";
|
|
43
49
|
import {
|
|
44
50
|
getDurationString
|
|
45
|
-
} from "./index-
|
|
46
|
-
import {
|
|
47
|
-
DEFAULT_PORT,
|
|
48
|
-
MAX_ERROR_LENGTH,
|
|
49
|
-
MILLISECONDS_IN_A_SECOND
|
|
50
|
-
} from "./index-czwrxgdj.js";
|
|
51
|
-
import {
|
|
52
|
-
__require
|
|
53
|
-
} from "./index-mywsk201.js";
|
|
51
|
+
} from "./index-1x1vah31.js";
|
|
54
52
|
|
|
55
53
|
// src/cli/scripts/start.ts
|
|
56
54
|
var {env } = globalThis.Bun;
|
|
57
55
|
import { existsSync, readFileSync, rmSync } from "fs";
|
|
58
56
|
import { basename, join, resolve } from "path";
|
|
59
|
-
var cliTag = (color, message) => `\x1B[2m${
|
|
57
|
+
var cliTag = (color, message) => `\x1B[2m${formatTimestamp2()}\x1B[0m ${color}[cli]\x1B[0m ${color}${message}\x1B[0m`;
|
|
60
58
|
var resolvePackageVersion = (candidates) => {
|
|
61
59
|
for (const candidate of candidates) {
|
|
62
60
|
const version = readPackageVersion(candidate);
|
|
@@ -127,7 +125,7 @@ var jsxDevRuntimeCompatPath = resolveJsxDevRuntimeCompatPath();
|
|
|
127
125
|
var prerenderStaticPages = async (outputPath, prerenderPort, resolvedOutdir, staticConfig, absoluteVersion, configPath) => {
|
|
128
126
|
const prerenderStart = performance.now();
|
|
129
127
|
process.stdout.write(cliTag("\x1B[36m", "Pre-rendering static pages"));
|
|
130
|
-
const { prerenderWithServer } = await import("./prerender-
|
|
128
|
+
const { prerenderWithServer } = await import("./prerender-mfnwsvyt.js");
|
|
131
129
|
try {
|
|
132
130
|
killStaleProcesses(prerenderPort);
|
|
133
131
|
const result = await prerenderWithServer(outputPath, prerenderPort, resolvedOutdir, staticConfig, {
|
|
@@ -212,7 +210,7 @@ var runPreparedServer = async ({
|
|
|
212
210
|
source: "start",
|
|
213
211
|
startedAt: new Date().toISOString()
|
|
214
212
|
});
|
|
215
|
-
const cleanup = async (
|
|
213
|
+
const cleanup = async (exitCode = 0) => {
|
|
216
214
|
if (cleaning)
|
|
217
215
|
return;
|
|
218
216
|
cleaning = true;
|
|
@@ -227,7 +225,7 @@ var runPreparedServer = async ({
|
|
|
227
225
|
await serverProcess.exited;
|
|
228
226
|
if (scripts)
|
|
229
227
|
await stopDatabase(scripts);
|
|
230
|
-
process.exit(
|
|
228
|
+
process.exit(exitCode);
|
|
231
229
|
};
|
|
232
230
|
process.on("SIGINT", () => cleanup(0));
|
|
233
231
|
process.on("SIGTERM", () => cleanup(0));
|
|
@@ -243,7 +241,7 @@ var runPreparedServer = async ({
|
|
|
243
241
|
await stopDatabase(scripts);
|
|
244
242
|
process.exit(exitCode);
|
|
245
243
|
};
|
|
246
|
-
var
|
|
244
|
+
var start2 = async (serverEntry, outdir, configPath, options = {}) => {
|
|
247
245
|
if (options.prebuilt && options.prepareOnly) {
|
|
248
246
|
throw new Error("A production start cannot be prebuilt and prepare-only.");
|
|
249
247
|
}
|
|
@@ -259,7 +257,7 @@ var start = async (serverEntry, outdir, configPath, options = {}) => {
|
|
|
259
257
|
buildConfig.buildDirectory = resolvedOutdir;
|
|
260
258
|
buildConfig.mode = "production";
|
|
261
259
|
if (buildConfig.mobile)
|
|
262
|
-
|
|
260
|
+
installAbsoluteMobileAuthEnvironment2(process.cwd(), normalizeAbsoluteMobileConfig2(buildConfig.mobile, process.cwd()));
|
|
263
261
|
const frameworks = [
|
|
264
262
|
buildConfig.reactDirectory && "react",
|
|
265
263
|
buildConfig.htmlDirectory && "html",
|
|
@@ -385,6 +383,7 @@ var start = async (serverEntry, outdir, configPath, options = {}) => {
|
|
|
385
383
|
external: resolveServerBundleExternals(buildConfig),
|
|
386
384
|
outdir: resolvedOutdir,
|
|
387
385
|
plugins: [
|
|
386
|
+
createOptionalPeerPlugin(),
|
|
388
387
|
...islandRegistryPlugin ? [islandRegistryPlugin] : [],
|
|
389
388
|
...buildConfig.mobile ? [
|
|
390
389
|
createAbsoluteMobileRouteMetadataPlugin({
|
|
@@ -421,7 +420,7 @@ var start = async (serverEntry, outdir, configPath, options = {}) => {
|
|
|
421
420
|
angularServerVendorPaths[specifier] = relPath.startsWith(".") ? relPath : `./${relPath}`;
|
|
422
421
|
}
|
|
423
422
|
if (Object.keys(angularServerVendorPaths).length > 0) {
|
|
424
|
-
const { rewriteImports } = await import("./rewriteImports-
|
|
423
|
+
const { rewriteImports } = await import("./rewriteImports-k6rjjmg1.js");
|
|
425
424
|
await rewriteImports([outputPath], angularServerVendorPaths);
|
|
426
425
|
}
|
|
427
426
|
}
|
|
@@ -467,4 +466,4 @@ var start = async (serverEntry, outdir, configPath, options = {}) => {
|
|
|
467
466
|
});
|
|
468
467
|
};
|
|
469
468
|
|
|
470
|
-
export {
|
|
469
|
+
export { start2 };
|
|
@@ -18,7 +18,7 @@ var __toESM = (mod, isNodeMode, target) => {
|
|
|
18
18
|
return cached;
|
|
19
19
|
}
|
|
20
20
|
target = mod != null ? __create(__getProtoOf(mod)) : {};
|
|
21
|
-
const to = isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target;
|
|
21
|
+
const to = isNodeMode || !mod || !mod.__esModule || !__hasOwnProp.call(mod, "default") ? __defProp(target, "default", { value: mod, enumerable: true }) : target;
|
|
22
22
|
if (mod && typeof mod === "object" || typeof mod === "function") {
|
|
23
23
|
for (let key of __getOwnPropNames(mod))
|
|
24
24
|
if (!__hasOwnProp.call(to, key))
|
|
@@ -1,16 +1,16 @@
|
|
|
1
1
|
// @bun
|
|
2
2
|
import {
|
|
3
|
-
|
|
4
|
-
} from "./index-
|
|
5
|
-
import {
|
|
6
|
-
normalizeAbsoluteMobileConfig
|
|
7
|
-
} from "./index-exdd5k1g.js";
|
|
3
|
+
normalizeAbsoluteMobileConfig2
|
|
4
|
+
} from "./index-rrxeqrbn.js";
|
|
8
5
|
import {
|
|
9
6
|
assertAbsoluteDeviceCapabilityPackages,
|
|
10
7
|
resolveAbsoluteMobileUpdateRuntime,
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
} from "./index-
|
|
8
|
+
writeAbsoluteExpoProject2,
|
|
9
|
+
syncAbsoluteExpoWebAssets2
|
|
10
|
+
} from "./index-5sjk7daj.js";
|
|
11
|
+
import {
|
|
12
|
+
toPascal
|
|
13
|
+
} from "./index-92g14j47.js";
|
|
14
14
|
|
|
15
15
|
// src/build/islandRegistryTransform.ts
|
|
16
16
|
import { basename } from "path";
|
|
@@ -650,8 +650,8 @@ var buildAbsoluteMobileCompatibilityRelease = async (options) => {
|
|
|
650
650
|
if (priorAppIds.size > 1 || priorAppIds.size === 1 && !priorAppIds.has(options.appId)) {
|
|
651
651
|
throw new TypeError("Previous mobile compatibility artifacts belong to another app.");
|
|
652
652
|
}
|
|
653
|
-
const unchanged = options.previousArtifacts?.find((
|
|
654
|
-
const generation = unchanged?.generation ?? Math.max(0, ...(options.previousArtifacts ?? []).map((
|
|
653
|
+
const unchanged = options.previousArtifacts?.find((artifact) => artifact.appBuild === appBuild && artifact.runtime === options.runtime);
|
|
654
|
+
const generation = unchanged?.generation ?? Math.max(0, ...(options.previousArtifacts ?? []).map((artifact) => artifact.generation)) + 1;
|
|
655
655
|
const artifact = createAbsoluteMobileCompatibilityArtifact({
|
|
656
656
|
appBuild,
|
|
657
657
|
appId: options.appId,
|
|
@@ -1370,7 +1370,7 @@ var loadServerApp = async (producerPath) => {
|
|
|
1370
1370
|
};
|
|
1371
1371
|
var finalizeAbsoluteMobileCompatibilityBuild = async (options) => {
|
|
1372
1372
|
const buildDirectory = resolve3(options.buildDirectory);
|
|
1373
|
-
const mobile =
|
|
1373
|
+
const mobile = normalizeAbsoluteMobileConfig2(options.mobile, options.projectRoot);
|
|
1374
1374
|
const root = join4(buildDirectory, ".absolutejs", "mobile-compatibility");
|
|
1375
1375
|
const [manifestSource, previous] = await Promise.all([
|
|
1376
1376
|
readFile4(join4(buildDirectory, "manifest.json"), "utf8"),
|
|
@@ -1446,10 +1446,10 @@ var finalizeAbsoluteMobileCompatibilityBuild = async (options) => {
|
|
|
1446
1446
|
...syncSchema ? { syncSchema: { components: syncSchema.components } } : {}
|
|
1447
1447
|
});
|
|
1448
1448
|
if (mobile.engine === "expo") {
|
|
1449
|
-
await
|
|
1449
|
+
await writeAbsoluteExpoProject2(mobile, {
|
|
1450
1450
|
projectRoot: options.projectRoot
|
|
1451
1451
|
});
|
|
1452
|
-
await
|
|
1452
|
+
await syncAbsoluteExpoWebAssets2(mobile);
|
|
1453
1453
|
}
|
|
1454
1454
|
return current.artifact;
|
|
1455
1455
|
};
|
|
@@ -1787,22 +1787,22 @@ var analyzeRouteCall = (node, sourceFile, checker, projectRoot) => {
|
|
|
1787
1787
|
if (!definition)
|
|
1788
1788
|
return;
|
|
1789
1789
|
if (definition.inputKind === "static") {
|
|
1790
|
-
const
|
|
1791
|
-
if (!
|
|
1790
|
+
const bundleKey = assetKey(input, checker);
|
|
1791
|
+
if (!bundleKey)
|
|
1792
1792
|
return;
|
|
1793
|
-
const
|
|
1794
|
-
const
|
|
1793
|
+
const pageId = `${definition.framework}:${bundleKey}`;
|
|
1794
|
+
const propsSchemaHash = hashAbsoluteMobilePropsSchema({
|
|
1795
1795
|
properties: {},
|
|
1796
1796
|
type: "object"
|
|
1797
1797
|
});
|
|
1798
1798
|
return {
|
|
1799
1799
|
inputKind: "static",
|
|
1800
1800
|
metadata: {
|
|
1801
|
-
bundleKey
|
|
1802
|
-
contract: `${definition.framework}:${
|
|
1801
|
+
bundleKey,
|
|
1802
|
+
contract: `${definition.framework}:${pageId}:${propsSchemaHash}`,
|
|
1803
1803
|
framework: definition.framework,
|
|
1804
|
-
pageId
|
|
1805
|
-
propsSchemaHash
|
|
1804
|
+
pageId,
|
|
1805
|
+
propsSchemaHash
|
|
1806
1806
|
},
|
|
1807
1807
|
pageCallStart: pageCall.getStart(sourceFile),
|
|
1808
1808
|
routeCallSpan: `${node.getStart(sourceFile)}:${node.end}`
|
|
@@ -1999,7 +1999,7 @@ var createElysiaOpenApiTypeboxPlugin = () => ({
|
|
|
1999
1999
|
|
|
2000
2000
|
// src/cli/serverBundleExternals.ts
|
|
2001
2001
|
import { existsSync as existsSync3, readFileSync as readFileSync2 } from "fs";
|
|
2002
|
-
import { join as join5 } from "path";
|
|
2002
|
+
import { dirname as dirname6, join as join5 } from "path";
|
|
2003
2003
|
var FRAMEWORK_EXTERNALS = [
|
|
2004
2004
|
"react",
|
|
2005
2005
|
"react/jsx-runtime",
|
|
@@ -2038,14 +2038,32 @@ var readManifest = (file) => {
|
|
|
2038
2038
|
return;
|
|
2039
2039
|
}
|
|
2040
2040
|
};
|
|
2041
|
-
var
|
|
2042
|
-
var collectMissingOptionalPeers = (projectRoot) => {
|
|
2041
|
+
var collectOptionalPeers = (projectRoot) => {
|
|
2043
2042
|
const app = readManifest(join5(projectRoot, "package.json"));
|
|
2044
|
-
|
|
2045
|
-
|
|
2046
|
-
|
|
2043
|
+
return [
|
|
2044
|
+
...new Set(Object.keys(app?.dependencies ?? {}).flatMap((dependency) => Object.entries(readManifest(join5(projectRoot, "node_modules", dependency, "package.json"))?.peerDependenciesMeta ?? {}).filter(([, meta]) => meta.optional === true).map(([peer]) => peer)))
|
|
2045
|
+
];
|
|
2047
2046
|
};
|
|
2048
|
-
var
|
|
2047
|
+
var escapeRegExp2 = (text) => text.replace(/[.*+?^${}()|[\]\\]/g, "\\$&");
|
|
2048
|
+
var createOptionalPeerPlugin = (projectRoot = process.cwd()) => ({
|
|
2049
|
+
name: "absolute-optional-peers",
|
|
2050
|
+
setup(build) {
|
|
2051
|
+
const peers = collectOptionalPeers(projectRoot);
|
|
2052
|
+
if (peers.length === 0)
|
|
2053
|
+
return;
|
|
2054
|
+
const filter = new RegExp(`^(?:${peers.map(escapeRegExp2).join("|")})(?:/.*)?$`);
|
|
2055
|
+
build.onResolve({ filter }, (args) => {
|
|
2056
|
+
const from = args.importer ? dirname6(args.importer) : projectRoot;
|
|
2057
|
+
try {
|
|
2058
|
+
Bun.resolveSync(args.path, from);
|
|
2059
|
+
return;
|
|
2060
|
+
} catch {
|
|
2061
|
+
return { external: true, path: args.path };
|
|
2062
|
+
}
|
|
2063
|
+
});
|
|
2064
|
+
}
|
|
2065
|
+
});
|
|
2066
|
+
var resolveServerBundleExternals = (buildConfig) => [
|
|
2049
2067
|
...FRAMEWORK_EXTERNALS.filter((specifier) => {
|
|
2050
2068
|
if (buildConfig.reactDirectory && (specifier === "react" || specifier.startsWith("react/") || specifier.startsWith("react-dom")))
|
|
2051
2069
|
return false;
|
|
@@ -2055,8 +2073,7 @@ var resolveServerBundleExternals = (buildConfig, projectRoot = process.cwd()) =>
|
|
|
2055
2073
|
return false;
|
|
2056
2074
|
return true;
|
|
2057
2075
|
}),
|
|
2058
|
-
...collectUserServerExternals(buildConfig)
|
|
2059
|
-
...collectMissingOptionalPeers(projectRoot)
|
|
2076
|
+
...collectUserServerExternals(buildConfig)
|
|
2060
2077
|
];
|
|
2061
2078
|
|
|
2062
|
-
export { createIslandRegistryDefinitionPlugin, createBunStringRawUnicodePlugin, resolveAbsoluteMobileRoute, ABSOLUTE_MOBILE_PAGE_PROTOCOL_VERSION, ABSOLUTE_MOBILE_CLIENT_MANIFEST_FORMAT, finalizeAbsoluteMobileCompatibilityBuild, createAbsoluteMobileRouteMetadataPlugin, createElysiaOpenApiTypeboxPlugin, resolveServerBundleExternals };
|
|
2079
|
+
export { createIslandRegistryDefinitionPlugin, createBunStringRawUnicodePlugin, resolveAbsoluteMobileRoute, ABSOLUTE_MOBILE_PAGE_PROTOCOL_VERSION, ABSOLUTE_MOBILE_CLIENT_MANIFEST_FORMAT, finalizeAbsoluteMobileCompatibilityBuild, createAbsoluteMobileRouteMetadataPlugin, createElysiaOpenApiTypeboxPlugin, createOptionalPeerPlugin, resolveServerBundleExternals };
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
// @bun
|
|
2
2
|
import {
|
|
3
3
|
isWSLEnvironment
|
|
4
|
-
} from "./index-
|
|
4
|
+
} from "./index-k4t9k1xk.js";
|
|
5
5
|
|
|
6
6
|
// src/mobile/emulatorDoctor.ts
|
|
7
7
|
import { access } from "fs/promises";
|
|
8
8
|
import { homedir } from "os";
|
|
9
9
|
import { join } from "path";
|
|
10
|
-
var
|
|
10
|
+
var ABSOLUTE_ANDROID_AVD_NAME2 = "AbsoluteJS_API_36";
|
|
11
11
|
var captureCommand = (command) => {
|
|
12
12
|
try {
|
|
13
13
|
const result = Bun.spawnSync(command, {
|
|
@@ -54,7 +54,7 @@ var windowsLocalAppDataFromWsl = () => {
|
|
|
54
54
|
return;
|
|
55
55
|
}
|
|
56
56
|
};
|
|
57
|
-
var
|
|
57
|
+
var absoluteManagedAndroidSdkRoot2 = (host, env = process.env) => {
|
|
58
58
|
if (host === "windows") {
|
|
59
59
|
return join(env.LOCALAPPDATA ?? join(homedir(), "AppData", "Local"), "AbsoluteJS", "Android", "Sdk");
|
|
60
60
|
}
|
|
@@ -74,7 +74,7 @@ var pathExists = async (path) => {
|
|
|
74
74
|
return false;
|
|
75
75
|
}
|
|
76
76
|
};
|
|
77
|
-
var
|
|
77
|
+
var detectAbsoluteMobileHost2 = (platform = process.platform, wsl = isWSLEnvironment()) => {
|
|
78
78
|
if (platform === "darwin")
|
|
79
79
|
return "macos";
|
|
80
80
|
if (platform === "win32")
|
|
@@ -115,13 +115,13 @@ var toolCheck = (id, label, platform, path, remediation) => path ? {
|
|
|
115
115
|
remediation,
|
|
116
116
|
status: "fail"
|
|
117
117
|
};
|
|
118
|
-
var
|
|
118
|
+
var inspectAbsoluteMobileToolchain2 = async (input = {}) => {
|
|
119
119
|
const env = input.env ?? process.env;
|
|
120
|
-
const host = input.host ??
|
|
120
|
+
const host = input.host ?? detectAbsoluteMobileHost2();
|
|
121
121
|
const exists = input.exists ?? pathExists;
|
|
122
122
|
const which = input.which ?? ((command) => Bun.which(command));
|
|
123
123
|
const capture = input.capture ?? captureCommand;
|
|
124
|
-
const androidRoot = input.androidRoot === null ? undefined : input.androidRoot ?? env.ANDROID_HOME ?? env.ANDROID_SDK_ROOT ??
|
|
124
|
+
const androidRoot = input.androidRoot === null ? undefined : input.androidRoot ?? env.ANDROID_HOME ?? env.ANDROID_SDK_ROOT ?? absoluteManagedAndroidSdkRoot2(host, env);
|
|
125
125
|
const windowsAndroidTools = host === "windows" || host === "wsl";
|
|
126
126
|
const android = (segments) => androidRoot ? join(androidRoot, ...segments) : undefined;
|
|
127
127
|
const paths = (values) => values.filter((value) => Boolean(value));
|
|
@@ -166,10 +166,10 @@ var inspectAbsoluteMobileToolchain = async (input = {}) => {
|
|
|
166
166
|
];
|
|
167
167
|
if (emulator) {
|
|
168
168
|
const avds = capture([emulator, "-list-avds"]);
|
|
169
|
-
const hasManagedAvd = avds.exitCode === 0 && avds.stdout.split(/\r?\n/).includes(
|
|
169
|
+
const hasManagedAvd = avds.exitCode === 0 && avds.stdout.split(/\r?\n/).includes(ABSOLUTE_ANDROID_AVD_NAME2);
|
|
170
170
|
checks.push({
|
|
171
171
|
id: "android.avd",
|
|
172
|
-
label: `AbsoluteJS Android emulator (${
|
|
172
|
+
label: `AbsoluteJS Android emulator (${ABSOLUTE_ANDROID_AVD_NAME2})`,
|
|
173
173
|
platform: "android",
|
|
174
174
|
remediation: hasManagedAvd ? undefined : "Run absolute mobile doctor android --fix to provision the managed emulator.",
|
|
175
175
|
status: hasManagedAvd ? "pass" : "fail"
|
|
@@ -225,4 +225,4 @@ var inspectAbsoluteMobileToolchain = async (input = {}) => {
|
|
|
225
225
|
return checks;
|
|
226
226
|
};
|
|
227
227
|
|
|
228
|
-
export {
|
|
228
|
+
export { ABSOLUTE_ANDROID_AVD_NAME2, absoluteManagedAndroidSdkRoot2, detectAbsoluteMobileHost2, inspectAbsoluteMobileToolchain2 };
|