hot-updater 0.16.4 → 0.16.6

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.
@@ -1,54 +1,71 @@
1
1
  /*! For license information please see babel.cjs.LICENSE.txt */
2
2
  var __webpack_modules__ = {
3
- "../../node_modules/.pnpm/picocolors@1.0.0/node_modules/picocolors/picocolors.js": function(module, __unused_webpack_exports, __webpack_require__) {
4
- let tty = __webpack_require__("tty");
5
- let isColorSupported = !("NO_COLOR" in process.env || process.argv.includes("--no-color")) && ("FORCE_COLOR" in process.env || process.argv.includes("--color") || "win32" === process.platform || tty.isatty(1) && "dumb" !== process.env.TERM || "CI" in process.env);
3
+ "../../node_modules/.pnpm/picocolors@1.1.1/node_modules/picocolors/picocolors.js": function(module) {
4
+ let p = process || {}, argv = p.argv || [], env = p.env || {};
5
+ let isColorSupported = !(!!env.NO_COLOR || argv.includes("--no-color")) && (!!env.FORCE_COLOR || argv.includes("--color") || "win32" === p.platform || (p.stdout || {}).isTTY && "dumb" !== env.TERM || !!env.CI);
6
6
  let formatter = (open, close, replace = open)=>(input)=>{
7
- let string = "" + input;
8
- let index = string.indexOf(close, open.length);
7
+ let string = "" + input, index = string.indexOf(close, open.length);
9
8
  return ~index ? open + replaceClose(string, close, replace, index) + close : open + string + close;
10
9
  };
11
10
  let replaceClose = (string, close, replace, index)=>{
12
- let start = string.substring(0, index) + replace;
13
- let end = string.substring(index + close.length);
14
- let nextIndex = end.indexOf(close);
15
- return ~nextIndex ? start + replaceClose(end, close, replace, nextIndex) : start + end;
11
+ let result = "", cursor = 0;
12
+ do {
13
+ result += string.substring(cursor, index) + replace;
14
+ cursor = index + close.length;
15
+ index = string.indexOf(close, cursor);
16
+ }while (~index);
17
+ return result + string.substring(cursor);
16
18
  };
17
- let createColors = (enabled = isColorSupported)=>({
19
+ let createColors = (enabled = isColorSupported)=>{
20
+ let f = enabled ? formatter : ()=>String;
21
+ return {
18
22
  isColorSupported: enabled,
19
- reset: enabled ? (s)=>`\x1b[0m${s}\x1b[0m` : String,
20
- bold: enabled ? formatter("\x1b[1m", "\x1b[22m", "\x1b[22m\x1b[1m") : String,
21
- dim: enabled ? formatter("\x1b[2m", "\x1b[22m", "\x1b[22m\x1b[2m") : String,
22
- italic: enabled ? formatter("\x1b[3m", "\x1b[23m") : String,
23
- underline: enabled ? formatter("\x1b[4m", "\x1b[24m") : String,
24
- inverse: enabled ? formatter("\x1b[7m", "\x1b[27m") : String,
25
- hidden: enabled ? formatter("\x1b[8m", "\x1b[28m") : String,
26
- strikethrough: enabled ? formatter("\x1b[9m", "\x1b[29m") : String,
27
- black: enabled ? formatter("\x1b[30m", "\x1b[39m") : String,
28
- red: enabled ? formatter("\x1b[31m", "\x1b[39m") : String,
29
- green: enabled ? formatter("\x1b[32m", "\x1b[39m") : String,
30
- yellow: enabled ? formatter("\x1b[33m", "\x1b[39m") : String,
31
- blue: enabled ? formatter("\x1b[34m", "\x1b[39m") : String,
32
- magenta: enabled ? formatter("\x1b[35m", "\x1b[39m") : String,
33
- cyan: enabled ? formatter("\x1b[36m", "\x1b[39m") : String,
34
- white: enabled ? formatter("\x1b[37m", "\x1b[39m") : String,
35
- gray: enabled ? formatter("\x1b[90m", "\x1b[39m") : String,
36
- bgBlack: enabled ? formatter("\x1b[40m", "\x1b[49m") : String,
37
- bgRed: enabled ? formatter("\x1b[41m", "\x1b[49m") : String,
38
- bgGreen: enabled ? formatter("\x1b[42m", "\x1b[49m") : String,
39
- bgYellow: enabled ? formatter("\x1b[43m", "\x1b[49m") : String,
40
- bgBlue: enabled ? formatter("\x1b[44m", "\x1b[49m") : String,
41
- bgMagenta: enabled ? formatter("\x1b[45m", "\x1b[49m") : String,
42
- bgCyan: enabled ? formatter("\x1b[46m", "\x1b[49m") : String,
43
- bgWhite: enabled ? formatter("\x1b[47m", "\x1b[49m") : String
44
- });
23
+ reset: f("\x1b[0m", "\x1b[0m"),
24
+ bold: f("\x1b[1m", "\x1b[22m", "\x1b[22m\x1b[1m"),
25
+ dim: f("\x1b[2m", "\x1b[22m", "\x1b[22m\x1b[2m"),
26
+ italic: f("\x1b[3m", "\x1b[23m"),
27
+ underline: f("\x1b[4m", "\x1b[24m"),
28
+ inverse: f("\x1b[7m", "\x1b[27m"),
29
+ hidden: f("\x1b[8m", "\x1b[28m"),
30
+ strikethrough: f("\x1b[9m", "\x1b[29m"),
31
+ black: f("\x1b[30m", "\x1b[39m"),
32
+ red: f("\x1b[31m", "\x1b[39m"),
33
+ green: f("\x1b[32m", "\x1b[39m"),
34
+ yellow: f("\x1b[33m", "\x1b[39m"),
35
+ blue: f("\x1b[34m", "\x1b[39m"),
36
+ magenta: f("\x1b[35m", "\x1b[39m"),
37
+ cyan: f("\x1b[36m", "\x1b[39m"),
38
+ white: f("\x1b[37m", "\x1b[39m"),
39
+ gray: f("\x1b[90m", "\x1b[39m"),
40
+ bgBlack: f("\x1b[40m", "\x1b[49m"),
41
+ bgRed: f("\x1b[41m", "\x1b[49m"),
42
+ bgGreen: f("\x1b[42m", "\x1b[49m"),
43
+ bgYellow: f("\x1b[43m", "\x1b[49m"),
44
+ bgBlue: f("\x1b[44m", "\x1b[49m"),
45
+ bgMagenta: f("\x1b[45m", "\x1b[49m"),
46
+ bgCyan: f("\x1b[46m", "\x1b[49m"),
47
+ bgWhite: f("\x1b[47m", "\x1b[49m"),
48
+ blackBright: f("\x1b[90m", "\x1b[39m"),
49
+ redBright: f("\x1b[91m", "\x1b[39m"),
50
+ greenBright: f("\x1b[92m", "\x1b[39m"),
51
+ yellowBright: f("\x1b[93m", "\x1b[39m"),
52
+ blueBright: f("\x1b[94m", "\x1b[39m"),
53
+ magentaBright: f("\x1b[95m", "\x1b[39m"),
54
+ cyanBright: f("\x1b[96m", "\x1b[39m"),
55
+ whiteBright: f("\x1b[97m", "\x1b[39m"),
56
+ bgBlackBright: f("\x1b[100m", "\x1b[49m"),
57
+ bgRedBright: f("\x1b[101m", "\x1b[49m"),
58
+ bgGreenBright: f("\x1b[102m", "\x1b[49m"),
59
+ bgYellowBright: f("\x1b[103m", "\x1b[49m"),
60
+ bgBlueBright: f("\x1b[104m", "\x1b[49m"),
61
+ bgMagentaBright: f("\x1b[105m", "\x1b[49m"),
62
+ bgCyanBright: f("\x1b[106m", "\x1b[49m"),
63
+ bgWhiteBright: f("\x1b[107m", "\x1b[49m")
64
+ };
65
+ };
45
66
  module.exports = createColors();
46
67
  module.exports.createColors = createColors;
47
68
  },
48
- tty: function(module) {
49
- "use strict";
50
- module.exports = require("tty");
51
- },
52
69
  "../../node_modules/.pnpm/@babel+helper-string-parser@7.25.9/node_modules/@babel/helper-string-parser/lib/index.js": function(__unused_webpack_module, exports1) {
53
70
  "use strict";
54
71
  Object.defineProperty(exports1, "__esModule", {
@@ -16944,7 +16961,7 @@ var __webpack_exports__ = {};
16944
16961
  var external_path_default = /*#__PURE__*/ __webpack_require__.n(external_path_namespaceObject);
16945
16962
  var lib = __webpack_require__("../../node_modules/.pnpm/@babel+types@7.26.0/node_modules/@babel/types/lib/index.js");
16946
16963
  const plugin_core_namespaceObject = require("@hot-updater/plugin-core");
16947
- var picocolors = __webpack_require__("../../node_modules/.pnpm/picocolors@1.0.0/node_modules/picocolors/picocolors.js");
16964
+ var picocolors = __webpack_require__("../../node_modules/.pnpm/picocolors@1.1.1/node_modules/picocolors/picocolors.js");
16948
16965
  var picocolors_default = /*#__PURE__*/ __webpack_require__.n(picocolors);
16949
16966
  /**
16950
16967
  * uuidv7: A JavaScript implementation of UUID version 7
@@ -17158,17 +17175,9 @@ var __webpack_exports__ = {};
17158
17175
  return {
17159
17176
  name: "replace-hot-updater-bundle-id",
17160
17177
  visitor: {
17161
- MemberExpression (path) {
17162
- if (lib.isIdentifier(path.node.object, {
17163
- name: "HotUpdater"
17164
- }) && lib.isIdentifier(path.node.property, {
17165
- name: "HOT_UPDATER_BUNDLE_ID"
17166
- })) path.replaceWith(lib.stringLiteral(bundleId));
17167
- if (lib.isIdentifier(path.node.object, {
17168
- name: "HotUpdater"
17169
- }) && lib.isIdentifier(path.node.property, {
17170
- name: "CHANNEL"
17171
- })) path.replaceWith(channel ? lib.stringLiteral(channel) : lib.nullLiteral());
17178
+ Identifier (path) {
17179
+ if ("__HOT_UPDATER_BUNDLE_ID" === path.node.name) path.replaceWith(lib.stringLiteral(bundleId));
17180
+ if ("__HOT_UPDATER_CHANNEL" === path.node.name) path.replaceWith(channel ? lib.stringLiteral(channel) : lib.nullLiteral());
17172
17181
  }
17173
17182
  }
17174
17183
  };
@@ -1,59 +1,76 @@
1
1
  /*! For license information please see babel.js.LICENSE.txt */
2
2
  import __rslib_shim_module__ from 'module';
3
3
  /*#__PURE__*/ import.meta.url;
4
- import * as __WEBPACK_EXTERNAL_MODULE_tty__ from "tty";
5
4
  import * as __WEBPACK_EXTERNAL_MODULE_fs__ from "fs";
6
5
  import * as __WEBPACK_EXTERNAL_MODULE_path__ from "path";
7
6
  import * as __WEBPACK_EXTERNAL_MODULE__hot_updater_plugin_core_40c1c502__ from "@hot-updater/plugin-core";
8
7
  var __webpack_modules__ = {
9
- "../../node_modules/.pnpm/picocolors@1.0.0/node_modules/picocolors/picocolors.js": function(module, __unused_webpack_exports, __webpack_require__) {
10
- let tty = __webpack_require__("tty");
11
- let isColorSupported = !("NO_COLOR" in process.env || process.argv.includes("--no-color")) && ("FORCE_COLOR" in process.env || process.argv.includes("--color") || "win32" === process.platform || tty.isatty(1) && "dumb" !== process.env.TERM || "CI" in process.env);
8
+ "../../node_modules/.pnpm/picocolors@1.1.1/node_modules/picocolors/picocolors.js": function(module) {
9
+ let p = process || {}, argv = p.argv || [], env = p.env || {};
10
+ let isColorSupported = !(!!env.NO_COLOR || argv.includes("--no-color")) && (!!env.FORCE_COLOR || argv.includes("--color") || "win32" === p.platform || (p.stdout || {}).isTTY && "dumb" !== env.TERM || !!env.CI);
12
11
  let formatter = (open, close, replace = open)=>(input)=>{
13
- let string = "" + input;
14
- let index = string.indexOf(close, open.length);
12
+ let string = "" + input, index = string.indexOf(close, open.length);
15
13
  return ~index ? open + replaceClose(string, close, replace, index) + close : open + string + close;
16
14
  };
17
15
  let replaceClose = (string, close, replace, index)=>{
18
- let start = string.substring(0, index) + replace;
19
- let end = string.substring(index + close.length);
20
- let nextIndex = end.indexOf(close);
21
- return ~nextIndex ? start + replaceClose(end, close, replace, nextIndex) : start + end;
16
+ let result = "", cursor = 0;
17
+ do {
18
+ result += string.substring(cursor, index) + replace;
19
+ cursor = index + close.length;
20
+ index = string.indexOf(close, cursor);
21
+ }while (~index);
22
+ return result + string.substring(cursor);
22
23
  };
23
- let createColors = (enabled = isColorSupported)=>({
24
+ let createColors = (enabled = isColorSupported)=>{
25
+ let f = enabled ? formatter : ()=>String;
26
+ return {
24
27
  isColorSupported: enabled,
25
- reset: enabled ? (s)=>`\x1b[0m${s}\x1b[0m` : String,
26
- bold: enabled ? formatter("\x1b[1m", "\x1b[22m", "\x1b[22m\x1b[1m") : String,
27
- dim: enabled ? formatter("\x1b[2m", "\x1b[22m", "\x1b[22m\x1b[2m") : String,
28
- italic: enabled ? formatter("\x1b[3m", "\x1b[23m") : String,
29
- underline: enabled ? formatter("\x1b[4m", "\x1b[24m") : String,
30
- inverse: enabled ? formatter("\x1b[7m", "\x1b[27m") : String,
31
- hidden: enabled ? formatter("\x1b[8m", "\x1b[28m") : String,
32
- strikethrough: enabled ? formatter("\x1b[9m", "\x1b[29m") : String,
33
- black: enabled ? formatter("\x1b[30m", "\x1b[39m") : String,
34
- red: enabled ? formatter("\x1b[31m", "\x1b[39m") : String,
35
- green: enabled ? formatter("\x1b[32m", "\x1b[39m") : String,
36
- yellow: enabled ? formatter("\x1b[33m", "\x1b[39m") : String,
37
- blue: enabled ? formatter("\x1b[34m", "\x1b[39m") : String,
38
- magenta: enabled ? formatter("\x1b[35m", "\x1b[39m") : String,
39
- cyan: enabled ? formatter("\x1b[36m", "\x1b[39m") : String,
40
- white: enabled ? formatter("\x1b[37m", "\x1b[39m") : String,
41
- gray: enabled ? formatter("\x1b[90m", "\x1b[39m") : String,
42
- bgBlack: enabled ? formatter("\x1b[40m", "\x1b[49m") : String,
43
- bgRed: enabled ? formatter("\x1b[41m", "\x1b[49m") : String,
44
- bgGreen: enabled ? formatter("\x1b[42m", "\x1b[49m") : String,
45
- bgYellow: enabled ? formatter("\x1b[43m", "\x1b[49m") : String,
46
- bgBlue: enabled ? formatter("\x1b[44m", "\x1b[49m") : String,
47
- bgMagenta: enabled ? formatter("\x1b[45m", "\x1b[49m") : String,
48
- bgCyan: enabled ? formatter("\x1b[46m", "\x1b[49m") : String,
49
- bgWhite: enabled ? formatter("\x1b[47m", "\x1b[49m") : String
50
- });
28
+ reset: f("\x1b[0m", "\x1b[0m"),
29
+ bold: f("\x1b[1m", "\x1b[22m", "\x1b[22m\x1b[1m"),
30
+ dim: f("\x1b[2m", "\x1b[22m", "\x1b[22m\x1b[2m"),
31
+ italic: f("\x1b[3m", "\x1b[23m"),
32
+ underline: f("\x1b[4m", "\x1b[24m"),
33
+ inverse: f("\x1b[7m", "\x1b[27m"),
34
+ hidden: f("\x1b[8m", "\x1b[28m"),
35
+ strikethrough: f("\x1b[9m", "\x1b[29m"),
36
+ black: f("\x1b[30m", "\x1b[39m"),
37
+ red: f("\x1b[31m", "\x1b[39m"),
38
+ green: f("\x1b[32m", "\x1b[39m"),
39
+ yellow: f("\x1b[33m", "\x1b[39m"),
40
+ blue: f("\x1b[34m", "\x1b[39m"),
41
+ magenta: f("\x1b[35m", "\x1b[39m"),
42
+ cyan: f("\x1b[36m", "\x1b[39m"),
43
+ white: f("\x1b[37m", "\x1b[39m"),
44
+ gray: f("\x1b[90m", "\x1b[39m"),
45
+ bgBlack: f("\x1b[40m", "\x1b[49m"),
46
+ bgRed: f("\x1b[41m", "\x1b[49m"),
47
+ bgGreen: f("\x1b[42m", "\x1b[49m"),
48
+ bgYellow: f("\x1b[43m", "\x1b[49m"),
49
+ bgBlue: f("\x1b[44m", "\x1b[49m"),
50
+ bgMagenta: f("\x1b[45m", "\x1b[49m"),
51
+ bgCyan: f("\x1b[46m", "\x1b[49m"),
52
+ bgWhite: f("\x1b[47m", "\x1b[49m"),
53
+ blackBright: f("\x1b[90m", "\x1b[39m"),
54
+ redBright: f("\x1b[91m", "\x1b[39m"),
55
+ greenBright: f("\x1b[92m", "\x1b[39m"),
56
+ yellowBright: f("\x1b[93m", "\x1b[39m"),
57
+ blueBright: f("\x1b[94m", "\x1b[39m"),
58
+ magentaBright: f("\x1b[95m", "\x1b[39m"),
59
+ cyanBright: f("\x1b[96m", "\x1b[39m"),
60
+ whiteBright: f("\x1b[97m", "\x1b[39m"),
61
+ bgBlackBright: f("\x1b[100m", "\x1b[49m"),
62
+ bgRedBright: f("\x1b[101m", "\x1b[49m"),
63
+ bgGreenBright: f("\x1b[102m", "\x1b[49m"),
64
+ bgYellowBright: f("\x1b[103m", "\x1b[49m"),
65
+ bgBlueBright: f("\x1b[104m", "\x1b[49m"),
66
+ bgMagentaBright: f("\x1b[105m", "\x1b[49m"),
67
+ bgCyanBright: f("\x1b[106m", "\x1b[49m"),
68
+ bgWhiteBright: f("\x1b[107m", "\x1b[49m")
69
+ };
70
+ };
51
71
  module.exports = createColors();
52
72
  module.exports.createColors = createColors;
53
73
  },
54
- tty: function(module) {
55
- module.exports = __WEBPACK_EXTERNAL_MODULE_tty__;
56
- },
57
74
  "../../node_modules/.pnpm/@babel+helper-string-parser@7.25.9/node_modules/@babel/helper-string-parser/lib/index.js": function(__unused_webpack_module, exports) {
58
75
  Object.defineProperty(exports, "__esModule", {
59
76
  value: true
@@ -16839,7 +16856,7 @@ function __webpack_require__(moduleId) {
16839
16856
  __webpack_require__.o = (obj, prop)=>Object.prototype.hasOwnProperty.call(obj, prop);
16840
16857
  })();
16841
16858
  var lib = __webpack_require__("../../node_modules/.pnpm/@babel+types@7.26.0/node_modules/@babel/types/lib/index.js");
16842
- var picocolors = __webpack_require__("../../node_modules/.pnpm/picocolors@1.0.0/node_modules/picocolors/picocolors.js");
16859
+ var picocolors = __webpack_require__("../../node_modules/.pnpm/picocolors@1.1.1/node_modules/picocolors/picocolors.js");
16843
16860
  var picocolors_default = /*#__PURE__*/ __webpack_require__.n(picocolors);
16844
16861
  /**
16845
16862
  * uuidv7: A JavaScript implementation of UUID version 7
@@ -17053,17 +17070,9 @@ function replaceHotUpdaterBundleId() {
17053
17070
  return {
17054
17071
  name: "replace-hot-updater-bundle-id",
17055
17072
  visitor: {
17056
- MemberExpression (path) {
17057
- if (lib.isIdentifier(path.node.object, {
17058
- name: "HotUpdater"
17059
- }) && lib.isIdentifier(path.node.property, {
17060
- name: "HOT_UPDATER_BUNDLE_ID"
17061
- })) path.replaceWith(lib.stringLiteral(bundleId));
17062
- if (lib.isIdentifier(path.node.object, {
17063
- name: "HotUpdater"
17064
- }) && lib.isIdentifier(path.node.property, {
17065
- name: "CHANNEL"
17066
- })) path.replaceWith(channel ? lib.stringLiteral(channel) : lib.nullLiteral());
17073
+ Identifier (path) {
17074
+ if ("__HOT_UPDATER_BUNDLE_ID" === path.node.name) path.replaceWith(lib.stringLiteral(bundleId));
17075
+ if ("__HOT_UPDATER_CHANNEL" === path.node.name) path.replaceWith(channel ? lib.stringLiteral(channel) : lib.nullLiteral());
17067
17076
  }
17068
17077
  }
17069
17078
  };
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "hot-updater",
3
3
  "type": "module",
4
- "version": "0.16.4",
4
+ "version": "0.16.6",
5
5
  "bin": {
6
6
  "hot-updater": "./dist/index.js"
7
7
  },
@@ -49,13 +49,13 @@
49
49
  },
50
50
  "dependencies": {
51
51
  "@clack/prompts": "^0.10.0",
52
- "@hot-updater/console": "0.16.4",
53
- "@hot-updater/core": "0.16.4",
54
- "@hot-updater/plugin-core": "0.16.4",
55
52
  "commander": "^11.1.0",
56
53
  "cosmiconfig": "^9.0.0",
57
54
  "cosmiconfig-typescript-loader": "^5.0.0",
58
- "es-git": "^0.2.0"
55
+ "es-git": "^0.2.0",
56
+ "@hot-updater/console": "0.16.6",
57
+ "@hot-updater/core": "0.16.6",
58
+ "@hot-updater/plugin-core": "0.16.6"
59
59
  },
60
60
  "devDependencies": {
61
61
  "@babel/core": "7.26.0",
@@ -81,7 +81,11 @@
81
81
  "plist": "^3.1.0",
82
82
  "read-package-up": "^11.0.0",
83
83
  "semver": "^7.6.3",
84
- "uuidv7": "^1.0.2"
84
+ "uuidv7": "^1.0.2",
85
+ "@hot-updater/cloudflare": "0.16.6",
86
+ "@hot-updater/firebase": "0.16.6",
87
+ "@hot-updater/supabase": "0.16.6",
88
+ "@hot-updater/aws": "0.16.6"
85
89
  },
86
90
  "peerDependencies": {
87
91
  "@hot-updater/aws": "*",