innetjs 2.3.0 → 2.3.2
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/bin/innet +7 -2
- package/index.js +8 -3
- package/index.mjs +8 -3
- package/package.json +3 -3
- package/bin/innet.d.ts +0 -2
package/bin/innet
CHANGED
|
@@ -191,6 +191,7 @@ const execAsync = node_util.promisify(exec);
|
|
|
191
191
|
const copyFiles = node_util.promisify(fs__default["default"].copy);
|
|
192
192
|
updateDotenv();
|
|
193
193
|
const REG_CLEAR_TEXT = /[\u001b\u009b][[()#;?]*(?:[0-9]{1,4}(?:;[0-9]{0,4})*)?[0-9A-ORZcf-nqry=><]/g;
|
|
194
|
+
const REG_RPT_ERROR_FILE = /(src[^:]+):(\d+):(\d+)/;
|
|
194
195
|
const REG_TJSX = /\.[tj]sx?$/;
|
|
195
196
|
const REG_EXT = /\.([^.]+)$/;
|
|
196
197
|
const scriptExtensions = ['ts', 'js', 'tsx', 'jsx'];
|
|
@@ -438,11 +439,15 @@ class InnetJS {
|
|
|
438
439
|
else if (e.error.code === 'PLUGIN_ERROR' && ['rpt2', 'commonjs'].includes(e.error.plugin)) {
|
|
439
440
|
const [, file, line, column] = e.error.message
|
|
440
441
|
.replace(REG_CLEAR_TEXT, '')
|
|
441
|
-
.match(
|
|
442
|
+
.match(REG_RPT_ERROR_FILE) || [];
|
|
442
443
|
logger__default["default"].end('Bundling', e.error.message);
|
|
443
444
|
if (file) {
|
|
444
445
|
console.log(`ERROR in ${file}:${line}:${column}`);
|
|
445
446
|
}
|
|
447
|
+
else if (e.error.loc) {
|
|
448
|
+
console.log(`ERROR in ${e.error.loc.file}:${e.error.loc.line}:${e.error.loc.column}`);
|
|
449
|
+
console.log(e.error.frame);
|
|
450
|
+
}
|
|
446
451
|
}
|
|
447
452
|
else {
|
|
448
453
|
logger__default["default"].end('Bundling', error ? e.error.stack : e.error.message);
|
|
@@ -764,7 +769,7 @@ class InnetJS {
|
|
|
764
769
|
}
|
|
765
770
|
|
|
766
771
|
(function () {
|
|
767
|
-
const env = {"__INNETJS__PACKAGE_VERSION":"2.3.
|
|
772
|
+
const env = {"__INNETJS__PACKAGE_VERSION":"2.3.2"};
|
|
768
773
|
if (typeof process === 'undefined') {
|
|
769
774
|
globalThis.process = { env: env };
|
|
770
775
|
} else if (process.env) {
|
package/index.js
CHANGED
|
@@ -72,8 +72,8 @@ var styles__default = /*#__PURE__*/_interopDefaultLegacy(styles);
|
|
|
72
72
|
var typescript__default = /*#__PURE__*/_interopDefaultLegacy(typescript);
|
|
73
73
|
var tmp__default = /*#__PURE__*/_interopDefaultLegacy(tmp);
|
|
74
74
|
|
|
75
|
-
(function () {
|
|
76
|
-
const env = {"__INNETJS__PACKAGE_VERSION":"2.3.
|
|
75
|
+
;(function () {
|
|
76
|
+
const env = {"__INNETJS__PACKAGE_VERSION":"2.3.2"};
|
|
77
77
|
if (typeof process === 'undefined') {
|
|
78
78
|
globalThis.process = { env: env };
|
|
79
79
|
} else if (process.env) {
|
|
@@ -90,6 +90,7 @@ const execAsync = node_util.promisify(exec);
|
|
|
90
90
|
const copyFiles = node_util.promisify(fs__default["default"].copy);
|
|
91
91
|
updateDotenv.updateDotenv();
|
|
92
92
|
const REG_CLEAR_TEXT = /[\u001b\u009b][[()#;?]*(?:[0-9]{1,4}(?:;[0-9]{0,4})*)?[0-9A-ORZcf-nqry=><]/g;
|
|
93
|
+
const REG_RPT_ERROR_FILE = /(src[^:]+):(\d+):(\d+)/;
|
|
93
94
|
const REG_TJSX = /\.[tj]sx?$/;
|
|
94
95
|
const REG_EXT = /\.([^.]+)$/;
|
|
95
96
|
const scriptExtensions = ['ts', 'js', 'tsx', 'jsx'];
|
|
@@ -337,11 +338,15 @@ class InnetJS {
|
|
|
337
338
|
else if (e.error.code === 'PLUGIN_ERROR' && ['rpt2', 'commonjs'].includes(e.error.plugin)) {
|
|
338
339
|
const [, file, line, column] = e.error.message
|
|
339
340
|
.replace(REG_CLEAR_TEXT, '')
|
|
340
|
-
.match(
|
|
341
|
+
.match(REG_RPT_ERROR_FILE) || [];
|
|
341
342
|
logger__default["default"].end('Bundling', e.error.message);
|
|
342
343
|
if (file) {
|
|
343
344
|
console.log(`ERROR in ${file}:${line}:${column}`);
|
|
344
345
|
}
|
|
346
|
+
else if (e.error.loc) {
|
|
347
|
+
console.log(`ERROR in ${e.error.loc.file}:${e.error.loc.line}:${e.error.loc.column}`);
|
|
348
|
+
console.log(e.error.frame);
|
|
349
|
+
}
|
|
345
350
|
}
|
|
346
351
|
else {
|
|
347
352
|
logger__default["default"].end('Bundling', error ? e.error.stack : e.error.message);
|
package/index.mjs
CHANGED
|
@@ -37,8 +37,8 @@ import { Extract } from './extract.mjs';
|
|
|
37
37
|
import { reporter, convertIndexFile, getFile } from './helpers.mjs';
|
|
38
38
|
import { updateDotenv } from './updateDotenv.mjs';
|
|
39
39
|
|
|
40
|
-
(function () {
|
|
41
|
-
const env = {"__INNETJS__PACKAGE_VERSION":"2.3.
|
|
40
|
+
;(function () {
|
|
41
|
+
const env = {"__INNETJS__PACKAGE_VERSION":"2.3.2"};
|
|
42
42
|
if (typeof process === 'undefined') {
|
|
43
43
|
globalThis.process = { env: env };
|
|
44
44
|
} else if (process.env) {
|
|
@@ -55,6 +55,7 @@ const execAsync = promisify(exec);
|
|
|
55
55
|
const copyFiles = promisify(fs.copy);
|
|
56
56
|
updateDotenv();
|
|
57
57
|
const REG_CLEAR_TEXT = /[\u001b\u009b][[()#;?]*(?:[0-9]{1,4}(?:;[0-9]{0,4})*)?[0-9A-ORZcf-nqry=><]/g;
|
|
58
|
+
const REG_RPT_ERROR_FILE = /(src[^:]+):(\d+):(\d+)/;
|
|
58
59
|
const REG_TJSX = /\.[tj]sx?$/;
|
|
59
60
|
const REG_EXT = /\.([^.]+)$/;
|
|
60
61
|
const scriptExtensions = ['ts', 'js', 'tsx', 'jsx'];
|
|
@@ -302,11 +303,15 @@ class InnetJS {
|
|
|
302
303
|
else if (e.error.code === 'PLUGIN_ERROR' && ['rpt2', 'commonjs'].includes(e.error.plugin)) {
|
|
303
304
|
const [, file, line, column] = e.error.message
|
|
304
305
|
.replace(REG_CLEAR_TEXT, '')
|
|
305
|
-
.match(
|
|
306
|
+
.match(REG_RPT_ERROR_FILE) || [];
|
|
306
307
|
logger.end('Bundling', e.error.message);
|
|
307
308
|
if (file) {
|
|
308
309
|
console.log(`ERROR in ${file}:${line}:${column}`);
|
|
309
310
|
}
|
|
311
|
+
else if (e.error.loc) {
|
|
312
|
+
console.log(`ERROR in ${e.error.loc.file}:${e.error.loc.line}:${e.error.loc.column}`);
|
|
313
|
+
console.log(e.error.frame);
|
|
314
|
+
}
|
|
310
315
|
}
|
|
311
316
|
else {
|
|
312
317
|
logger.end('Bundling', error ? e.error.stack : e.error.message);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "innetjs",
|
|
3
|
-
"version": "2.3.
|
|
3
|
+
"version": "2.3.2",
|
|
4
4
|
"description": "CLI for innet boilerplate",
|
|
5
5
|
"homepage": "https://github.com/d8corp/innetjs",
|
|
6
6
|
"author": "Mikhail Lysikov <d8corp@mail.ru>",
|
|
@@ -14,14 +14,14 @@
|
|
|
14
14
|
"innetjs": "bin/innet"
|
|
15
15
|
},
|
|
16
16
|
"scripts": {
|
|
17
|
-
"build": "innetjs release
|
|
17
|
+
"build": "innetjs release",
|
|
18
18
|
"test": "jest",
|
|
19
19
|
"lint": "eslint src --ext .ts,.tsx",
|
|
20
20
|
"lint:fix": "eslint src --ext .ts,.tsx --fix",
|
|
21
21
|
"start": "npm run build && cd release && npm link",
|
|
22
22
|
"stop": "npm unlink innetjs -g",
|
|
23
23
|
"restart": "npm run stop && npm start",
|
|
24
|
-
"release": "innetjs release -
|
|
24
|
+
"release": "innetjs release -p",
|
|
25
25
|
"patch": "innetjs patch",
|
|
26
26
|
"minor": "innetjs minor",
|
|
27
27
|
"major": "innetjs major"
|
package/bin/innet.d.ts
DELETED