hot-updater 0.21.6 → 0.21.8
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/chunk-DWy1uDak.cjs +39 -0
- package/dist/config.cjs +1 -2
- package/dist/config.d.cts +2 -1
- package/dist/config.d.ts +2 -1
- package/dist/config.js +1 -2
- package/dist/{fingerprint-CUyLNgcg.js → fingerprint-BBD702SI.js} +34 -9
- package/dist/{fingerprint-xeLO0LG3.cjs → fingerprint-DqX6r8Tm.cjs} +184 -187
- package/dist/index.cjs +768 -704
- package/dist/index.js +379 -316
- package/dist/plugins/babel.cjs +6 -5
- package/dist/plugins/babel.js +2 -3
- package/package.json +11 -12
- package/dist/picocolors-O3YZQBCJ.js +0 -99
- package/dist/picocolors-y8lGs7d-.cjs +0 -114
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
//#region rolldown:runtime
|
|
2
|
+
var __create = Object.create;
|
|
3
|
+
var __defProp = Object.defineProperty;
|
|
4
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
5
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
6
|
+
var __getProtoOf = Object.getPrototypeOf;
|
|
7
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
8
|
+
var __commonJS = (cb, mod) => function() {
|
|
9
|
+
return mod || (0, cb[__getOwnPropNames(cb)[0]])((mod = { exports: {} }).exports, mod), mod.exports;
|
|
10
|
+
};
|
|
11
|
+
var __copyProps = (to, from, except, desc) => {
|
|
12
|
+
if (from && typeof from === "object" || typeof from === "function") for (var keys = __getOwnPropNames(from), i = 0, n = keys.length, key; i < n; i++) {
|
|
13
|
+
key = keys[i];
|
|
14
|
+
if (!__hasOwnProp.call(to, key) && key !== except) __defProp(to, key, {
|
|
15
|
+
get: ((k) => from[k]).bind(null, key),
|
|
16
|
+
enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
|
|
17
|
+
});
|
|
18
|
+
}
|
|
19
|
+
return to;
|
|
20
|
+
};
|
|
21
|
+
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", {
|
|
22
|
+
value: mod,
|
|
23
|
+
enumerable: true
|
|
24
|
+
}) : target, mod));
|
|
25
|
+
|
|
26
|
+
//#endregion
|
|
27
|
+
|
|
28
|
+
Object.defineProperty(exports, '__commonJS', {
|
|
29
|
+
enumerable: true,
|
|
30
|
+
get: function () {
|
|
31
|
+
return __commonJS;
|
|
32
|
+
}
|
|
33
|
+
});
|
|
34
|
+
Object.defineProperty(exports, '__toESM', {
|
|
35
|
+
enumerable: true,
|
|
36
|
+
get: function () {
|
|
37
|
+
return __toESM;
|
|
38
|
+
}
|
|
39
|
+
});
|
package/dist/config.cjs
CHANGED
package/dist/config.d.cts
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { HotUpdaterConfigOptions } from "@hot-updater/cli-tools";
|
|
2
|
+
import { ConfigInput, Platform } from "@hot-updater/plugin-core";
|
|
2
3
|
import { FingerprintSource } from "@expo/fingerprint";
|
|
3
4
|
|
|
4
5
|
//#region src/utils/fingerprint/common.d.ts
|
package/dist/config.d.ts
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { HotUpdaterConfigOptions } from "@hot-updater/cli-tools";
|
|
2
2
|
import { FingerprintSource } from "@expo/fingerprint";
|
|
3
|
+
import { ConfigInput, Platform } from "@hot-updater/plugin-core";
|
|
3
4
|
|
|
4
5
|
//#region src/utils/fingerprint/common.d.ts
|
|
5
6
|
|
package/dist/config.js
CHANGED
|
@@ -1,5 +1,4 @@
|
|
|
1
|
-
import "./
|
|
2
|
-
import { i as generateFingerprints, n as createFingerprintJSON, o as readLocalFingerprint, r as generateFingerprint, t as createAndInjectFingerprintFiles } from "./fingerprint-CUyLNgcg.js";
|
|
1
|
+
import { i as generateFingerprints, n as createFingerprintJSON, o as readLocalFingerprint, r as generateFingerprint, t as createAndInjectFingerprintFiles } from "./fingerprint-BBD702SI.js";
|
|
3
2
|
|
|
4
3
|
//#region src/config.ts
|
|
5
4
|
const defineConfig = (config) => {
|
|
@@ -1,10 +1,36 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import
|
|
3
|
-
import { getCwd, loadConfig } from "@hot-updater/plugin-core";
|
|
1
|
+
import { createRequire } from "node:module";
|
|
2
|
+
import { colors, getCwd, loadConfig, p } from "@hot-updater/cli-tools";
|
|
4
3
|
import path from "path";
|
|
5
4
|
import fs from "fs";
|
|
6
5
|
import { SourceSkips, createFingerprintAsync, diffFingerprintChangesAsync } from "@expo/fingerprint";
|
|
7
6
|
|
|
7
|
+
//#region rolldown:runtime
|
|
8
|
+
var __create = Object.create;
|
|
9
|
+
var __defProp = Object.defineProperty;
|
|
10
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
11
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
12
|
+
var __getProtoOf = Object.getPrototypeOf;
|
|
13
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
14
|
+
var __commonJS = (cb, mod) => function() {
|
|
15
|
+
return mod || (0, cb[__getOwnPropNames(cb)[0]])((mod = { exports: {} }).exports, mod), mod.exports;
|
|
16
|
+
};
|
|
17
|
+
var __copyProps = (to, from, except, desc) => {
|
|
18
|
+
if (from && typeof from === "object" || typeof from === "function") for (var keys = __getOwnPropNames(from), i$1 = 0, n = keys.length, key; i$1 < n; i$1++) {
|
|
19
|
+
key = keys[i$1];
|
|
20
|
+
if (!__hasOwnProp.call(to, key) && key !== except) __defProp(to, key, {
|
|
21
|
+
get: ((k) => from[k]).bind(null, key),
|
|
22
|
+
enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
|
|
23
|
+
});
|
|
24
|
+
}
|
|
25
|
+
return to;
|
|
26
|
+
};
|
|
27
|
+
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", {
|
|
28
|
+
value: mod,
|
|
29
|
+
enumerable: true
|
|
30
|
+
}) : target, mod));
|
|
31
|
+
var __require = /* @__PURE__ */ createRequire(import.meta.url);
|
|
32
|
+
|
|
33
|
+
//#endregion
|
|
8
34
|
//#region ../../node_modules/.pnpm/fast-xml-parser@5.2.3/node_modules/fast-xml-parser/src/util.js
|
|
9
35
|
const nameStartChar$1 = ":A-Za-z_\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD";
|
|
10
36
|
nameStartChar$1 + "";
|
|
@@ -14798,7 +14824,6 @@ function isFingerprintEquals(lhs, rhs) {
|
|
|
14798
14824
|
|
|
14799
14825
|
//#endregion
|
|
14800
14826
|
//#region src/utils/fingerprint/diff.ts
|
|
14801
|
-
var import_picocolors = /* @__PURE__ */ __toESM(require_picocolors(), 1);
|
|
14802
14827
|
async function getFingerprintDiff(oldFingerprint, options) {
|
|
14803
14828
|
const projectPath = getCwd();
|
|
14804
14829
|
return await diffFingerprintChangesAsync(oldFingerprint, projectPath, getOtaFingerprintOptions(options.platform, projectPath, options));
|
|
@@ -14809,13 +14834,13 @@ function getSourcePath(source) {
|
|
|
14809
14834
|
}
|
|
14810
14835
|
function showFingerprintDiff(diff, platform) {
|
|
14811
14836
|
if (diff.length === 0) return;
|
|
14812
|
-
p.log.info(`${
|
|
14837
|
+
p.log.info(`${colors.bold(`${platform} Fingerprint Changes:`)}`);
|
|
14813
14838
|
const added = diff.filter((item) => item.op === "added");
|
|
14814
14839
|
const removed = diff.filter((item) => item.op === "removed");
|
|
14815
14840
|
const changed = diff.filter((item) => item.op === "changed");
|
|
14816
|
-
if (added.length > 0) p.log.info(` ${
|
|
14817
|
-
if (removed.length > 0) p.log.info(` ${
|
|
14818
|
-
if (changed.length > 0) p.log.info(` ${
|
|
14841
|
+
if (added.length > 0) p.log.info(` ${colors.green("Added:")} ${added.map((item) => getSourcePath(item.addedSource)).join(", ")}`);
|
|
14842
|
+
if (removed.length > 0) p.log.info(` ${colors.red("Removed:")} ${removed.map((item) => getSourcePath(item.removedSource)).join(", ")}`);
|
|
14843
|
+
if (changed.length > 0) p.log.info(` ${colors.yellow("Changed:")} ${changed.map((item) => getSourcePath(item.beforeSource)).join(", ")}`);
|
|
14819
14844
|
}
|
|
14820
14845
|
|
|
14821
14846
|
//#endregion
|
|
@@ -14898,4 +14923,4 @@ const readLocalFingerprint = async () => {
|
|
|
14898
14923
|
};
|
|
14899
14924
|
|
|
14900
14925
|
//#endregion
|
|
14901
|
-
export { nativeFingerprint as a, showFingerprintDiff as c, IosConfigParser as d, require_plist as f, generateFingerprints as i, isFingerprintEquals as l, AndroidConfigParser as m, createFingerprintJSON as n, readLocalFingerprint as o, require_base64_js as p, generateFingerprint as r, getFingerprintDiff as s, createAndInjectFingerprintFiles as t, require_out as u };
|
|
14926
|
+
export { __toESM as _, nativeFingerprint as a, showFingerprintDiff as c, IosConfigParser as d, require_plist as f, __require as g, __commonJS as h, generateFingerprints as i, isFingerprintEquals as l, AndroidConfigParser as m, createFingerprintJSON as n, readLocalFingerprint as o, require_base64_js as p, generateFingerprint as r, getFingerprintDiff as s, createAndInjectFingerprintFiles as t, require_out as u };
|