@hot-updater/sentry-plugin 0.20.10 → 0.20.12
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/index.cjs +5 -6
- package/dist/index.js +3 -4
- package/package.json +3 -3
package/dist/index.cjs
CHANGED
|
@@ -21,14 +21,14 @@ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__ge
|
|
|
21
21
|
}) : target, mod));
|
|
22
22
|
|
|
23
23
|
//#endregion
|
|
24
|
-
let fs = require("fs");
|
|
25
|
-
fs = __toESM(fs);
|
|
26
|
-
let path = require("path");
|
|
27
|
-
path = __toESM(path);
|
|
28
24
|
let __hot_updater_plugin_core = require("@hot-updater/plugin-core");
|
|
29
25
|
__hot_updater_plugin_core = __toESM(__hot_updater_plugin_core);
|
|
30
26
|
let __sentry_cli = require("@sentry/cli");
|
|
31
27
|
__sentry_cli = __toESM(__sentry_cli);
|
|
28
|
+
let fs = require("fs");
|
|
29
|
+
fs = __toESM(fs);
|
|
30
|
+
let path = require("path");
|
|
31
|
+
path = __toESM(path);
|
|
32
32
|
|
|
33
33
|
//#region src/withSentry.ts
|
|
34
34
|
const injectDebugIdToHbcMap = (jsCodePath, jsMapPath, hbcMapPath) => {
|
|
@@ -36,8 +36,7 @@ const injectDebugIdToHbcMap = (jsCodePath, jsMapPath, hbcMapPath) => {
|
|
|
36
36
|
const jsMap = JSON.parse(fs.default.readFileSync(jsMapPath, "utf8"));
|
|
37
37
|
let debugId = jsMap.debug_id || jsMap.debugId;
|
|
38
38
|
if (!debugId) {
|
|
39
|
-
const
|
|
40
|
-
const debugIdMatch = jsCode.match(/\/\/# debugId=([a-f0-9-]+)/);
|
|
39
|
+
const debugIdMatch = fs.default.readFileSync(jsCodePath, "utf8").match(/\/\/# debugId=([a-f0-9-]+)/);
|
|
41
40
|
debugId = debugIdMatch ? debugIdMatch[1] : void 0;
|
|
42
41
|
if (!debugId) throw new Error("debugId from Source map not found. It seems hot-updater doesn't support Sentry plugin with this bundle framework. Please pile issue on Github.");
|
|
43
42
|
}
|
package/dist/index.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import fs from "fs";
|
|
2
|
-
import path from "path";
|
|
3
1
|
import { getCwd } from "@hot-updater/plugin-core";
|
|
4
2
|
import SentryCli from "@sentry/cli";
|
|
3
|
+
import fs from "fs";
|
|
4
|
+
import path from "path";
|
|
5
5
|
|
|
6
6
|
//#region src/withSentry.ts
|
|
7
7
|
const injectDebugIdToHbcMap = (jsCodePath, jsMapPath, hbcMapPath) => {
|
|
@@ -9,8 +9,7 @@ const injectDebugIdToHbcMap = (jsCodePath, jsMapPath, hbcMapPath) => {
|
|
|
9
9
|
const jsMap = JSON.parse(fs.readFileSync(jsMapPath, "utf8"));
|
|
10
10
|
let debugId = jsMap.debug_id || jsMap.debugId;
|
|
11
11
|
if (!debugId) {
|
|
12
|
-
const
|
|
13
|
-
const debugIdMatch = jsCode.match(/\/\/# debugId=([a-f0-9-]+)/);
|
|
12
|
+
const debugIdMatch = fs.readFileSync(jsCodePath, "utf8").match(/\/\/# debugId=([a-f0-9-]+)/);
|
|
14
13
|
debugId = debugIdMatch ? debugIdMatch[1] : void 0;
|
|
15
14
|
if (!debugId) throw new Error("debugId from Source map not found. It seems hot-updater doesn't support Sentry plugin with this bundle framework. Please pile issue on Github.");
|
|
16
15
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@hot-updater/sentry-plugin",
|
|
3
|
-
"version": "0.20.
|
|
3
|
+
"version": "0.20.12",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "React Native OTA solution for self-hosted",
|
|
6
6
|
"sideEffects": false,
|
|
@@ -39,8 +39,8 @@
|
|
|
39
39
|
},
|
|
40
40
|
"dependencies": {
|
|
41
41
|
"@sentry/cli": "2.46.0",
|
|
42
|
-
"@hot-updater/core": "0.20.
|
|
43
|
-
"@hot-updater/plugin-core": "0.20.
|
|
42
|
+
"@hot-updater/core": "0.20.12",
|
|
43
|
+
"@hot-updater/plugin-core": "0.20.12"
|
|
44
44
|
},
|
|
45
45
|
"devDependencies": {
|
|
46
46
|
"@types/node": "^20"
|