extension-develop 3.2.3 → 3.3.1
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/547.js +2 -1
- package/dist/552.js +3 -2
- package/dist/extension-js-theme/chrome/manifest.json +15 -15
- package/dist/extension-js-theme/chromium/manifest.json +15 -15
- package/dist/extension-js-theme/edge/manifest.json +15 -15
- package/dist/extension-js-theme/firefox/manifest.json +1 -60
- package/dist/module.js +262 -136
- package/package.json +1 -1
package/dist/547.js
CHANGED
|
@@ -8586,7 +8586,8 @@ Set background.noDynamicEntryWarning to true to disable this warning.
|
|
|
8586
8586
|
});
|
|
8587
8587
|
function scrubBrand(txt, brand = 'Extension.js') {
|
|
8588
8588
|
if (!txt) return txt;
|
|
8589
|
-
|
|
8589
|
+
const safeBrand = brand.replace(/\$/g, '$$$$');
|
|
8590
|
+
return txt.replace(RegExp("(?<!@)\\bRspack\\b", "gi"), safeBrand).replace(RegExp("(?<!@)\\bWebpack\\b", "gi"), safeBrand).replace(RegExp("(?<!@)\\bwebpack-dev-server\\b", "gi"), `${safeBrand} dev server`).replace(RegExp("(?<!@)\\bRspackDevServer\\b", "gi"), `${safeBrand} dev server`).replace(/ModuleBuildError:\s*/g, '').replace(/ModuleParseError:\s*/g, '').replace(/Error:\s*Module\s+build\s+failed.*?\n/gi, '').replace(/\n{3,}/g, '\n\n');
|
|
8590
8591
|
}
|
|
8591
8592
|
function makeSanitizedConsole(brand = 'Extension.js') {
|
|
8592
8593
|
const sanitize = (a)=>'string' == typeof a ? scrubBrand(a, brand) : a;
|
package/dist/552.js
CHANGED
|
@@ -10,7 +10,8 @@ exports.modules = {
|
|
|
10
10
|
});
|
|
11
11
|
function scrubBrand(txt, brand = 'Extension.js') {
|
|
12
12
|
if (!txt) return txt;
|
|
13
|
-
|
|
13
|
+
const safeBrand = brand.replace(/\$/g, '$$$$');
|
|
14
|
+
return txt.replace(RegExp("(?<!@)\\bRspack\\b", "gi"), safeBrand).replace(RegExp("(?<!@)\\bWebpack\\b", "gi"), safeBrand).replace(RegExp("(?<!@)\\bwebpack-dev-server\\b", "gi"), `${safeBrand} dev server`).replace(RegExp("(?<!@)\\bRspackDevServer\\b", "gi"), `${safeBrand} dev server`).replace(/ModuleBuildError:\s*/g, '').replace(/ModuleParseError:\s*/g, '').replace(/Error:\s*Module\s+build\s+failed.*?\n/gi, '').replace(/\n{3,}/g, '\n\n');
|
|
14
15
|
}
|
|
15
16
|
function makeSanitizedConsole(brand = 'Extension.js') {
|
|
16
17
|
const sanitize = (a)=>'string' == typeof a ? scrubBrand(a, brand) : a;
|
|
@@ -46,7 +47,7 @@ exports.modules = {
|
|
|
46
47
|
errors: true,
|
|
47
48
|
warnings: true
|
|
48
49
|
});
|
|
49
|
-
if (str) console.error(str);
|
|
50
|
+
if (str) console.error((0, _branding__rspack_import_0.h)(str));
|
|
50
51
|
} catch {}
|
|
51
52
|
}
|
|
52
53
|
}
|
|
@@ -7,24 +7,24 @@
|
|
|
7
7
|
"theme": {
|
|
8
8
|
"colors": {
|
|
9
9
|
"frame": [
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
10
|
+
18,
|
|
11
|
+
18,
|
|
12
|
+
20
|
|
13
13
|
],
|
|
14
14
|
"frame_inactive": [
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
15
|
+
15,
|
|
16
|
+
15,
|
|
17
|
+
17
|
|
18
18
|
],
|
|
19
19
|
"toolbar": [
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
20
|
+
30,
|
|
21
|
+
30,
|
|
22
|
+
32
|
|
23
23
|
],
|
|
24
24
|
"tab_background_text": [
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
25
|
+
185,
|
|
26
|
+
185,
|
|
27
|
+
191
|
|
28
28
|
],
|
|
29
29
|
"tab_text": [
|
|
30
30
|
255,
|
|
@@ -32,9 +32,9 @@
|
|
|
32
32
|
255
|
|
33
33
|
],
|
|
34
34
|
"tab_background_text_inactive": [
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
35
|
+
168,
|
|
36
|
+
168,
|
|
37
|
+
174
|
|
38
38
|
],
|
|
39
39
|
"tab_text_inactive": [
|
|
40
40
|
255,
|
|
@@ -7,24 +7,24 @@
|
|
|
7
7
|
"theme": {
|
|
8
8
|
"colors": {
|
|
9
9
|
"frame": [
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
10
|
+
18,
|
|
11
|
+
18,
|
|
12
|
+
20
|
|
13
13
|
],
|
|
14
14
|
"frame_inactive": [
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
15
|
+
15,
|
|
16
|
+
15,
|
|
17
|
+
17
|
|
18
18
|
],
|
|
19
19
|
"toolbar": [
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
20
|
+
30,
|
|
21
|
+
30,
|
|
22
|
+
32
|
|
23
23
|
],
|
|
24
24
|
"tab_background_text": [
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
25
|
+
185,
|
|
26
|
+
185,
|
|
27
|
+
191
|
|
28
28
|
],
|
|
29
29
|
"tab_text": [
|
|
30
30
|
255,
|
|
@@ -32,9 +32,9 @@
|
|
|
32
32
|
255
|
|
33
33
|
],
|
|
34
34
|
"tab_background_text_inactive": [
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
35
|
+
168,
|
|
36
|
+
168,
|
|
37
|
+
174
|
|
38
38
|
],
|
|
39
39
|
"tab_text_inactive": [
|
|
40
40
|
255,
|
|
@@ -7,24 +7,24 @@
|
|
|
7
7
|
"theme": {
|
|
8
8
|
"colors": {
|
|
9
9
|
"frame": [
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
10
|
+
18,
|
|
11
|
+
18,
|
|
12
|
+
20
|
|
13
13
|
],
|
|
14
14
|
"frame_inactive": [
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
15
|
+
15,
|
|
16
|
+
15,
|
|
17
|
+
17
|
|
18
18
|
],
|
|
19
19
|
"toolbar": [
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
20
|
+
30,
|
|
21
|
+
30,
|
|
22
|
+
32
|
|
23
23
|
],
|
|
24
24
|
"tab_background_text": [
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
25
|
+
185,
|
|
26
|
+
185,
|
|
27
|
+
191
|
|
28
28
|
],
|
|
29
29
|
"tab_text": [
|
|
30
30
|
255,
|
|
@@ -32,9 +32,9 @@
|
|
|
32
32
|
255
|
|
33
33
|
],
|
|
34
34
|
"tab_background_text_inactive": [
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
35
|
+
168,
|
|
36
|
+
168,
|
|
37
|
+
174
|
|
38
38
|
],
|
|
39
39
|
"tab_text_inactive": [
|
|
40
40
|
255,
|
|
@@ -3,64 +3,5 @@
|
|
|
3
3
|
"name": "Custom theme",
|
|
4
4
|
"version": "1.0",
|
|
5
5
|
"description": "A clean, minimal browser theme generated in the editor.",
|
|
6
|
-
"author": "Anonymous"
|
|
7
|
-
"theme": {
|
|
8
|
-
"colors": {
|
|
9
|
-
"frame": [
|
|
10
|
-
37,
|
|
11
|
-
37,
|
|
12
|
-
39
|
|
13
|
-
],
|
|
14
|
-
"frame_inactive": [
|
|
15
|
-
49,
|
|
16
|
-
49,
|
|
17
|
-
53
|
|
18
|
-
],
|
|
19
|
-
"toolbar": [
|
|
20
|
-
25,
|
|
21
|
-
25,
|
|
22
|
-
26
|
|
23
|
-
],
|
|
24
|
-
"tab_background_text": [
|
|
25
|
-
28,
|
|
26
|
-
28,
|
|
27
|
-
30
|
|
28
|
-
],
|
|
29
|
-
"tab_text": [
|
|
30
|
-
255,
|
|
31
|
-
255,
|
|
32
|
-
255
|
|
33
|
-
],
|
|
34
|
-
"tab_background_text_inactive": [
|
|
35
|
-
62,
|
|
36
|
-
62,
|
|
37
|
-
66
|
|
38
|
-
],
|
|
39
|
-
"tab_text_inactive": [
|
|
40
|
-
255,
|
|
41
|
-
255,
|
|
42
|
-
255
|
|
43
|
-
],
|
|
44
|
-
"bookmark_text": [
|
|
45
|
-
153,
|
|
46
|
-
153,
|
|
47
|
-
159
|
|
48
|
-
],
|
|
49
|
-
"ntp_background": [
|
|
50
|
-
28,
|
|
51
|
-
28,
|
|
52
|
-
30
|
|
53
|
-
],
|
|
54
|
-
"ntp_text": [
|
|
55
|
-
255,
|
|
56
|
-
255,
|
|
57
|
-
255
|
|
58
|
-
],
|
|
59
|
-
"button_background": [
|
|
60
|
-
28,
|
|
61
|
-
28,
|
|
62
|
-
30
|
|
63
|
-
]
|
|
64
|
-
}
|
|
65
|
-
}
|
|
6
|
+
"author": "Anonymous"
|
|
66
7
|
}
|
package/dist/module.js
CHANGED
|
@@ -130602,8 +130602,8 @@ var __webpack_modules__ = {
|
|
|
130602
130602
|
var path__rspack_import_0 = __webpack_require__("path");
|
|
130603
130603
|
var fs__rspack_import_1 = __webpack_require__("fs");
|
|
130604
130604
|
var child_process__rspack_import_2 = __webpack_require__("child_process");
|
|
130605
|
-
var
|
|
130606
|
-
var
|
|
130605
|
+
var _messages__rspack_import_3 = __webpack_require__("./webpack/plugin-css/css-lib/messages.ts");
|
|
130606
|
+
var _webpack_lib_check_build_dependencies__rspack_import_4 = __webpack_require__("./webpack/webpack-lib/check-build-dependencies.ts");
|
|
130607
130607
|
function parseJsonSafe(text) {
|
|
130608
130608
|
const s = text && 0xfeff === text.charCodeAt(0) ? text.slice(1) : text;
|
|
130609
130609
|
return JSON.parse(s || '{}');
|
|
@@ -130632,80 +130632,158 @@ var __webpack_modules__ = {
|
|
|
130632
130632
|
if (execPath.includes('npm')) return 'npm';
|
|
130633
130633
|
}
|
|
130634
130634
|
}
|
|
130635
|
-
function getLogPrefix(type) {
|
|
130636
|
-
if ('true' === process.env.EXTENSION_AUTHOR_MODE) {
|
|
130637
|
-
const base = 'error' === type ? 'ERROR Author says' : '►►► Author says';
|
|
130638
|
-
return pintor__rspack_import_3_default().brightMagenta(base);
|
|
130639
|
-
}
|
|
130640
|
-
return 'error' === type ? pintor__rspack_import_3_default().red('ERROR') : pintor__rspack_import_3_default().gray('►►►');
|
|
130641
|
-
}
|
|
130642
130635
|
async function resolvePackageManager() {
|
|
130643
130636
|
const envPm = getPackageManagerFromEnv();
|
|
130644
130637
|
if (envPm) return envPm;
|
|
130645
130638
|
return 'npm';
|
|
130646
130639
|
}
|
|
130647
|
-
function
|
|
130648
|
-
const
|
|
130640
|
+
function resolveDevelopInstallRoot() {
|
|
130641
|
+
const directRoot = (0, _webpack_lib_check_build_dependencies__rspack_import_4.w1)();
|
|
130642
|
+
if (directRoot) return directRoot;
|
|
130643
|
+
try {
|
|
130644
|
+
const pkgPath = require.resolve('extension-develop/package.json', {
|
|
130645
|
+
paths: [
|
|
130646
|
+
process.cwd()
|
|
130647
|
+
]
|
|
130648
|
+
});
|
|
130649
|
+
return path__rspack_import_0.dirname(pkgPath);
|
|
130650
|
+
} catch {
|
|
130651
|
+
return;
|
|
130652
|
+
}
|
|
130653
|
+
}
|
|
130654
|
+
function getOptionalInstallCommand(pm, dependencies, installBaseDir) {
|
|
130649
130655
|
const pmName = pm;
|
|
130650
|
-
if ('yarn' === pmName) return
|
|
130651
|
-
|
|
130652
|
-
|
|
130656
|
+
if ('yarn' === pmName) return {
|
|
130657
|
+
command: 'yarn',
|
|
130658
|
+
args: [
|
|
130659
|
+
'--silent',
|
|
130660
|
+
'add',
|
|
130661
|
+
...dependencies,
|
|
130662
|
+
'--cwd',
|
|
130663
|
+
installBaseDir,
|
|
130664
|
+
'--optional'
|
|
130665
|
+
]
|
|
130666
|
+
};
|
|
130667
|
+
if ('npm' === pmName || isFromNpx()) return {
|
|
130668
|
+
command: 'npm',
|
|
130669
|
+
args: [
|
|
130670
|
+
'--silent',
|
|
130671
|
+
'install',
|
|
130672
|
+
...dependencies,
|
|
130673
|
+
'--prefix',
|
|
130674
|
+
installBaseDir,
|
|
130675
|
+
'--save-optional'
|
|
130676
|
+
]
|
|
130677
|
+
};
|
|
130678
|
+
if (isFromPnpx()) return {
|
|
130679
|
+
command: 'pnpm',
|
|
130680
|
+
args: [
|
|
130681
|
+
'--silent',
|
|
130682
|
+
'add',
|
|
130683
|
+
...dependencies,
|
|
130684
|
+
'--prefix',
|
|
130685
|
+
installBaseDir,
|
|
130686
|
+
'--save-optional'
|
|
130687
|
+
]
|
|
130688
|
+
};
|
|
130653
130689
|
const fallback = pmName || 'npm';
|
|
130654
|
-
return
|
|
130690
|
+
return {
|
|
130691
|
+
command: fallback,
|
|
130692
|
+
args: [
|
|
130693
|
+
'--silent',
|
|
130694
|
+
'install',
|
|
130695
|
+
...dependencies,
|
|
130696
|
+
'--cwd',
|
|
130697
|
+
installBaseDir,
|
|
130698
|
+
'--optional'
|
|
130699
|
+
]
|
|
130700
|
+
};
|
|
130655
130701
|
}
|
|
130656
130702
|
function getRootInstallCommand(pm) {
|
|
130657
130703
|
const pmName = pm;
|
|
130658
|
-
if ('yarn' === pmName) return
|
|
130659
|
-
|
|
130660
|
-
|
|
130661
|
-
|
|
130662
|
-
|
|
130663
|
-
|
|
130664
|
-
|
|
130665
|
-
|
|
130704
|
+
if ('yarn' === pmName) return {
|
|
130705
|
+
command: 'yarn',
|
|
130706
|
+
args: [
|
|
130707
|
+
'install',
|
|
130708
|
+
'--silent'
|
|
130709
|
+
]
|
|
130710
|
+
};
|
|
130711
|
+
if ('npm' === pmName || isFromNpx()) return {
|
|
130712
|
+
command: 'npm',
|
|
130713
|
+
args: [
|
|
130714
|
+
'install',
|
|
130715
|
+
'--silent'
|
|
130716
|
+
]
|
|
130717
|
+
};
|
|
130718
|
+
if (isFromPnpx()) return {
|
|
130719
|
+
command: 'pnpm',
|
|
130720
|
+
args: [
|
|
130721
|
+
'install',
|
|
130722
|
+
'--silent'
|
|
130723
|
+
]
|
|
130724
|
+
};
|
|
130725
|
+
return {
|
|
130726
|
+
command: pmName || 'npm',
|
|
130727
|
+
args: [
|
|
130728
|
+
'install',
|
|
130729
|
+
'--silent'
|
|
130730
|
+
]
|
|
130731
|
+
};
|
|
130666
130732
|
}
|
|
130667
130733
|
async function installOptionalDependencies(integration, dependencies) {
|
|
130668
130734
|
if (!dependencies.length) return;
|
|
130669
130735
|
try {
|
|
130670
130736
|
const pm = await resolvePackageManager();
|
|
130671
|
-
const
|
|
130672
|
-
|
|
130737
|
+
const installBaseDir = resolveDevelopInstallRoot() || process.cwd();
|
|
130738
|
+
const installCommand = getOptionalInstallCommand(pm, dependencies, installBaseDir);
|
|
130739
|
+
const isAuthor = 'true' === process.env.EXTENSION_AUTHOR_MODE;
|
|
130740
|
+
console.log(_messages__rspack_import_3._j([
|
|
130673
130741
|
integration
|
|
130674
|
-
], integration));
|
|
130675
|
-
(0, child_process__rspack_import_2.
|
|
130676
|
-
stdio: 'inherit'
|
|
130742
|
+
], integration, isAuthor));
|
|
130743
|
+
(0, child_process__rspack_import_2.execFileSync)(installCommand.command, installCommand.args, {
|
|
130744
|
+
stdio: 'inherit',
|
|
130745
|
+
cwd: installBaseDir
|
|
130677
130746
|
});
|
|
130678
|
-
await new Promise((
|
|
130679
|
-
if (
|
|
130680
|
-
console.log(
|
|
130681
|
-
|
|
130682
|
-
|
|
130747
|
+
await new Promise((resolve)=>setTimeout(resolve, 500));
|
|
130748
|
+
if (isAuthor) {
|
|
130749
|
+
console.log(_messages__rspack_import_3.cr(integration));
|
|
130750
|
+
const rootInstall = getRootInstallCommand(pm);
|
|
130751
|
+
(0, child_process__rspack_import_2.execFileSync)(rootInstall.command, rootInstall.args, {
|
|
130752
|
+
stdio: 'ignore',
|
|
130753
|
+
cwd: installBaseDir
|
|
130683
130754
|
});
|
|
130684
|
-
console.log(
|
|
130755
|
+
console.log(_messages__rspack_import_3.ys(integration));
|
|
130685
130756
|
}
|
|
130686
130757
|
} catch (error) {
|
|
130687
|
-
|
|
130758
|
+
const isAuthor = 'true' === process.env.EXTENSION_AUTHOR_MODE;
|
|
130759
|
+
console.error(_messages__rspack_import_3.DX(integration, error, isAuthor));
|
|
130688
130760
|
}
|
|
130689
130761
|
}
|
|
130690
130762
|
async function installOptionalDependenciesBatch(integration, dependencies, integrations) {
|
|
130691
130763
|
if (!dependencies.length) return;
|
|
130692
130764
|
try {
|
|
130693
130765
|
const pm = await resolvePackageManager();
|
|
130694
|
-
const
|
|
130695
|
-
|
|
130696
|
-
|
|
130697
|
-
|
|
130766
|
+
const installBaseDir = resolveDevelopInstallRoot() || process.cwd();
|
|
130767
|
+
const installCommand = getOptionalInstallCommand(pm, dependencies, installBaseDir);
|
|
130768
|
+
const isAuthor = 'true' === process.env.EXTENSION_AUTHOR_MODE;
|
|
130769
|
+
console.log(_messages__rspack_import_3._j(integrations, integration, isAuthor));
|
|
130770
|
+
(0, child_process__rspack_import_2.execFileSync)(installCommand.command, installCommand.args, {
|
|
130771
|
+
stdio: 'inherit',
|
|
130772
|
+
cwd: installBaseDir
|
|
130698
130773
|
});
|
|
130699
|
-
await new Promise((
|
|
130700
|
-
if (
|
|
130701
|
-
console.log(
|
|
130702
|
-
|
|
130703
|
-
|
|
130774
|
+
await new Promise((resolve)=>setTimeout(resolve, 500));
|
|
130775
|
+
if (isAuthor) {
|
|
130776
|
+
console.log(_messages__rspack_import_3.cr(integration));
|
|
130777
|
+
const rootInstall = getRootInstallCommand(pm);
|
|
130778
|
+
(0, child_process__rspack_import_2.execFileSync)(rootInstall.command, rootInstall.args, {
|
|
130779
|
+
stdio: 'ignore',
|
|
130780
|
+
cwd: installBaseDir
|
|
130704
130781
|
});
|
|
130705
|
-
console.log(
|
|
130782
|
+
console.log(_messages__rspack_import_3.ys(integration));
|
|
130706
130783
|
}
|
|
130707
130784
|
} catch (error) {
|
|
130708
|
-
|
|
130785
|
+
const isAuthor = 'true' === process.env.EXTENSION_AUTHOR_MODE;
|
|
130786
|
+
console.error(_messages__rspack_import_3.DX(integration, error, isAuthor));
|
|
130709
130787
|
}
|
|
130710
130788
|
}
|
|
130711
130789
|
function hasDependency(projectPath, dependency) {
|
|
@@ -130755,10 +130833,14 @@ var __webpack_modules__ = {
|
|
|
130755
130833
|
"./webpack/plugin-css/css-lib/messages.ts" (__unused_rspack_module, __webpack_exports__, __webpack_require__) {
|
|
130756
130834
|
"use strict";
|
|
130757
130835
|
__webpack_require__.d(__webpack_exports__, {
|
|
130836
|
+
DX: ()=>optionalInstallFailed,
|
|
130758
130837
|
Jv: ()=>youAreAllSet,
|
|
130759
130838
|
Se: ()=>missingSassDependency,
|
|
130839
|
+
_j: ()=>optionalToolingSetup,
|
|
130840
|
+
cr: ()=>optionalToolingRootInstall,
|
|
130760
130841
|
fD: ()=>cssConfigsDetected,
|
|
130761
130842
|
uo: ()=>cssIntegrationsEnabled,
|
|
130843
|
+
ys: ()=>optionalToolingReady,
|
|
130762
130844
|
zA: ()=>isUsingIntegration
|
|
130763
130845
|
});
|
|
130764
130846
|
var pintor__rspack_import_0 = __webpack_require__("pintor");
|
|
@@ -130777,6 +130859,21 @@ var __webpack_modules__ = {
|
|
|
130777
130859
|
function youAreAllSet(name) {
|
|
130778
130860
|
return `${pintor__rspack_import_0_default().green('►►►')} ${name} installation completed.`;
|
|
130779
130861
|
}
|
|
130862
|
+
function optionalToolingSetup(integrations, fallback, isAuthor) {
|
|
130863
|
+
const list = integrations && integrations.length > 0 ? integrations.join('/') : fallback;
|
|
130864
|
+
const prefix = isAuthor ? pintor__rspack_import_0_default().brightMagenta('►►► Author says') : pintor__rspack_import_0_default().gray('►►►');
|
|
130865
|
+
return `${prefix} Setting up ${list} tooling... (this is a one time op)`;
|
|
130866
|
+
}
|
|
130867
|
+
function optionalToolingRootInstall(integration) {
|
|
130868
|
+
return `${pintor__rspack_import_0_default().brightMagenta('►►► Author says')} [${integration}] Installing root dependencies for dev...`;
|
|
130869
|
+
}
|
|
130870
|
+
function optionalToolingReady(integration) {
|
|
130871
|
+
return `${pintor__rspack_import_0_default().brightMagenta('►►► Author says')} ${integration} tooling ready.`;
|
|
130872
|
+
}
|
|
130873
|
+
function optionalInstallFailed(integration, error, isAuthor) {
|
|
130874
|
+
const prefix = isAuthor ? pintor__rspack_import_0_default().brightMagenta('ERROR Author says') : pintor__rspack_import_0_default().red('ERROR');
|
|
130875
|
+
return `${prefix} [${integration}] Failed to install dependencies.\n${pintor__rspack_import_0_default().red(String(error?.message || error))}`;
|
|
130876
|
+
}
|
|
130780
130877
|
function missingSassDependency() {
|
|
130781
130878
|
const prefix = pintor__rspack_import_0_default().red('►►►');
|
|
130782
130879
|
return [
|
|
@@ -131727,6 +131824,50 @@ var __webpack_modules__ = {
|
|
|
131727
131824
|
};
|
|
131728
131825
|
}
|
|
131729
131826
|
},
|
|
131827
|
+
"./webpack/webpack-lib/check-build-dependencies.ts" (__unused_rspack_module, __webpack_exports__, __webpack_require__) {
|
|
131828
|
+
"use strict";
|
|
131829
|
+
__webpack_require__.d(__webpack_exports__, {
|
|
131830
|
+
Cf: ()=>getMissingBuildDependencies,
|
|
131831
|
+
S: ()=>areBuildDependenciesInstalled,
|
|
131832
|
+
Wb: ()=>loadBuildDependencies,
|
|
131833
|
+
w1: ()=>findExtensionDevelopRoot
|
|
131834
|
+
});
|
|
131835
|
+
var path__rspack_import_0 = __webpack_require__("path");
|
|
131836
|
+
var fs__rspack_import_1 = __webpack_require__("fs");
|
|
131837
|
+
function findExtensionDevelopRoot() {
|
|
131838
|
+
const webpackLibDir = __dirname;
|
|
131839
|
+
const webpackDir = path__rspack_import_0.resolve(webpackLibDir, '..');
|
|
131840
|
+
const packageRoot = path__rspack_import_0.resolve(webpackDir, '..');
|
|
131841
|
+
const packageJsonPath = path__rspack_import_0.join(packageRoot, 'package.json');
|
|
131842
|
+
if (fs__rspack_import_1.existsSync(packageJsonPath)) try {
|
|
131843
|
+
const pkg = JSON.parse(fs__rspack_import_1.readFileSync(packageJsonPath, 'utf-8'));
|
|
131844
|
+
if ('extension-develop' === pkg.name) return packageRoot;
|
|
131845
|
+
} catch {}
|
|
131846
|
+
return null;
|
|
131847
|
+
}
|
|
131848
|
+
function loadBuildDependencies() {
|
|
131849
|
+
const metadataPath = path__rspack_import_0.join(__dirname, 'build-dependencies.json');
|
|
131850
|
+
if (!fs__rspack_import_1.existsSync(metadataPath)) throw new Error(`build-dependencies.json not found at ${metadataPath}. This indicates a corrupted installation.`);
|
|
131851
|
+
try {
|
|
131852
|
+
const content = fs__rspack_import_1.readFileSync(metadataPath, 'utf-8');
|
|
131853
|
+
return JSON.parse(content);
|
|
131854
|
+
} catch (error) {
|
|
131855
|
+
throw new Error(`Failed to load build-dependencies.json: ${error.message}`);
|
|
131856
|
+
}
|
|
131857
|
+
}
|
|
131858
|
+
function isDependencyInstalled(dependency, packageRoot) {
|
|
131859
|
+
const nodeModulesPath = path__rspack_import_0.join(packageRoot, 'node_modules', dependency);
|
|
131860
|
+
return fs__rspack_import_1.existsSync(nodeModulesPath);
|
|
131861
|
+
}
|
|
131862
|
+
function areBuildDependenciesInstalled(packageRoot) {
|
|
131863
|
+
const dependencies = loadBuildDependencies();
|
|
131864
|
+
return Object.keys(dependencies).every((dep)=>isDependencyInstalled(dep, packageRoot));
|
|
131865
|
+
}
|
|
131866
|
+
function getMissingBuildDependencies(packageRoot) {
|
|
131867
|
+
const dependencies = loadBuildDependencies();
|
|
131868
|
+
return Object.keys(dependencies).filter((dep)=>!isDependencyInstalled(dep, packageRoot));
|
|
131869
|
+
}
|
|
131870
|
+
},
|
|
131730
131871
|
"./webpack/webpack-lib/companion-extensions.ts" (__unused_rspack_module, __webpack_exports__, __webpack_require__) {
|
|
131731
131872
|
"use strict";
|
|
131732
131873
|
__webpack_require__.d(__webpack_exports__, {
|
|
@@ -132626,7 +132767,7 @@ var __webpack_modules__ = {
|
|
|
132626
132767
|
},
|
|
132627
132768
|
"./package.json" (module) {
|
|
132628
132769
|
"use strict";
|
|
132629
|
-
module.exports = JSON.parse('{"rE":"3.
|
|
132770
|
+
module.exports = JSON.parse('{"rE":"3.3.1","El":{"@rspack/core":"^1.7.2","@rspack/dev-server":"^1.1.5","@swc/core":"^1.15.8","@swc/helpers":"^0.5.18","adm-zip":"^0.5.16","browser-extension-manifest-fields":"^2.2.1","case-sensitive-paths-webpack-plugin":"^2.4.0","chrome-location2":"4.0.0","chromium-location":"2.0.0","content-security-policy-parser":"^0.6.0","cross-spawn":"^7.0.6","dotenv":"^17.2.3","edge-location":"2.2.0","firefox-location2":"3.0.0","go-git-it":"^5.0.3","ignore":"^7.0.5","loader-utils":"^3.3.1","magic-string":"^0.30.21","parse5":"^8.0.0","parse5-utilities":"^1.0.0","pintor":"0.3.0","schema-utils":"^4.3.3","tiny-glob":"^0.2.9","unique-names-generator":"^4.7.1","webextension-polyfill":"^0.12.0","webpack-merge":"^6.0.1","webpack-target-webextension":"^2.1.3","ws":"^8.19.0"}}');
|
|
132630
132771
|
}
|
|
132631
132772
|
};
|
|
132632
132773
|
var __webpack_module_cache__ = {};
|
|
@@ -132937,40 +133078,8 @@ var __webpack_exports__ = {};
|
|
|
132937
133078
|
if ('true' === process.env.EXTENSION_AUTHOR_MODE) console.warn(error);
|
|
132938
133079
|
}
|
|
132939
133080
|
}
|
|
132940
|
-
var
|
|
132941
|
-
|
|
132942
|
-
const webpackLibDir = __dirname;
|
|
132943
|
-
const webpackDir = external_path_.resolve(webpackLibDir, '..');
|
|
132944
|
-
const packageRoot = external_path_.resolve(webpackDir, '..');
|
|
132945
|
-
const packageJsonPath = external_path_.join(packageRoot, 'package.json');
|
|
132946
|
-
if (external_fs_.existsSync(packageJsonPath)) try {
|
|
132947
|
-
const pkg = JSON.parse(external_fs_.readFileSync(packageJsonPath, 'utf-8'));
|
|
132948
|
-
if ('extension-develop' === pkg.name) return packageRoot;
|
|
132949
|
-
} catch {}
|
|
132950
|
-
return null;
|
|
132951
|
-
}
|
|
132952
|
-
function loadBuildDependencies() {
|
|
132953
|
-
const metadataPath = external_path_.join(__dirname, 'build-dependencies.json');
|
|
132954
|
-
if (!external_fs_.existsSync(metadataPath)) throw new Error(`build-dependencies.json not found at ${metadataPath}. This indicates a corrupted installation.`);
|
|
132955
|
-
try {
|
|
132956
|
-
const content = external_fs_.readFileSync(metadataPath, 'utf-8');
|
|
132957
|
-
return JSON.parse(content);
|
|
132958
|
-
} catch (error) {
|
|
132959
|
-
throw new Error(`Failed to load build-dependencies.json: ${error.message}`);
|
|
132960
|
-
}
|
|
132961
|
-
}
|
|
132962
|
-
function isDependencyInstalled(dependency, packageRoot) {
|
|
132963
|
-
const nodeModulesPath = external_path_.join(packageRoot, 'node_modules', dependency);
|
|
132964
|
-
return external_fs_.existsSync(nodeModulesPath);
|
|
132965
|
-
}
|
|
132966
|
-
function areBuildDependenciesInstalled(packageRoot) {
|
|
132967
|
-
const dependencies = loadBuildDependencies();
|
|
132968
|
-
return Object.keys(dependencies).every((dep)=>isDependencyInstalled(dep, packageRoot));
|
|
132969
|
-
}
|
|
132970
|
-
function getMissingBuildDependencies(packageRoot) {
|
|
132971
|
-
const dependencies = loadBuildDependencies();
|
|
132972
|
-
return Object.keys(dependencies).filter((dep)=>!isDependencyInstalled(dep, packageRoot));
|
|
132973
|
-
}
|
|
133081
|
+
var webpack_lib_paths = __webpack_require__("./webpack/webpack-lib/paths.ts");
|
|
133082
|
+
var check_build_dependencies = __webpack_require__("./webpack/webpack-lib/check-build-dependencies.ts");
|
|
132974
133083
|
const external_cross_spawn_namespaceObject = require("cross-spawn");
|
|
132975
133084
|
function detectPackageManagerFromEnv() {
|
|
132976
133085
|
const userAgent = process.env.npm_config_user_agent || '';
|
|
@@ -133015,7 +133124,7 @@ var __webpack_exports__ = {};
|
|
|
133015
133124
|
async function installOwnDependencies(dependencies, packageRoot) {
|
|
133016
133125
|
if (0 === dependencies.length) return;
|
|
133017
133126
|
if (!packageRoot) throw new Error('Package root is required for dependency installation');
|
|
133018
|
-
const dependenciesMap =
|
|
133127
|
+
const dependenciesMap = (0, check_build_dependencies.Wb)();
|
|
133019
133128
|
const missingFromMetadata = dependencies.filter((dep)=>!(dep in dependenciesMap));
|
|
133020
133129
|
if (missingFromMetadata.length > 0) throw new Error(`Dependencies not found in build-dependencies.json: ${missingFromMetadata.join(', ')}`);
|
|
133021
133130
|
const originalDirectory = process.cwd();
|
|
@@ -133088,9 +133197,9 @@ var __webpack_exports__ = {};
|
|
|
133088
133197
|
}
|
|
133089
133198
|
}
|
|
133090
133199
|
async function ensureDependencies(projectPath, opts) {
|
|
133091
|
-
const packageRoot =
|
|
133092
|
-
const missingBuild = packageRoot && !
|
|
133093
|
-
const shouldInstallUserDeps = !!projectPath && !opts?.skipProjectInstall && (0,
|
|
133200
|
+
const packageRoot = (0, check_build_dependencies.w1)();
|
|
133201
|
+
const missingBuild = packageRoot && !(0, check_build_dependencies.S)(packageRoot) ? (0, check_build_dependencies.Cf)(packageRoot) : [];
|
|
133202
|
+
const shouldInstallUserDeps = !!projectPath && !opts?.skipProjectInstall && (0, webpack_lib_paths.Bi)((0, webpack_lib_paths.G6)(projectPath));
|
|
133094
133203
|
const needsBuildInstall = missingBuild.length > 0;
|
|
133095
133204
|
const needsUserInstall = shouldInstallUserDeps;
|
|
133096
133205
|
if (!needsBuildInstall && !needsUserInstall) return {
|
|
@@ -133170,7 +133279,7 @@ var __webpack_exports__ = {};
|
|
|
133170
133279
|
}
|
|
133171
133280
|
}
|
|
133172
133281
|
function getPreflightMarkerPath(projectPath) {
|
|
133173
|
-
const packageRoot =
|
|
133282
|
+
const packageRoot = (0, check_build_dependencies.w1)();
|
|
133174
133283
|
if (!packageRoot) return;
|
|
133175
133284
|
const cacheDir = getPreflightCacheDir(packageRoot);
|
|
133176
133285
|
return external_path_.join(cacheDir, `${getProjectKey(projectPath)}.json`);
|
|
@@ -133230,27 +133339,35 @@ var __webpack_exports__ = {};
|
|
|
133230
133339
|
var less = __webpack_require__("./webpack/plugin-css/css-tools/less.ts");
|
|
133231
133340
|
var postcss = __webpack_require__("./webpack/plugin-css/css-tools/postcss.ts");
|
|
133232
133341
|
var js_frameworks_lib_messages = __webpack_require__("./webpack/plugin-js-frameworks/js-frameworks-lib/messages.ts");
|
|
133342
|
+
function getResolutionPaths(projectPath) {
|
|
133343
|
+
const extensionRoot = (0, check_build_dependencies.w1)();
|
|
133344
|
+
const paths = [
|
|
133345
|
+
projectPath || void 0,
|
|
133346
|
+
extensionRoot || void 0,
|
|
133347
|
+
process.cwd()
|
|
133348
|
+
].filter(Boolean);
|
|
133349
|
+
return Array.from(new Set(paths));
|
|
133350
|
+
}
|
|
133233
133351
|
function canResolveFromProject(id, projectPath) {
|
|
133234
133352
|
try {
|
|
133235
133353
|
return require.resolve(id, {
|
|
133236
|
-
paths:
|
|
133237
|
-
projectPath,
|
|
133238
|
-
process.cwd()
|
|
133239
|
-
]
|
|
133354
|
+
paths: getResolutionPaths(projectPath)
|
|
133240
133355
|
});
|
|
133241
133356
|
} catch {
|
|
133242
133357
|
return;
|
|
133243
133358
|
}
|
|
133244
133359
|
}
|
|
133245
|
-
function canResolve(id) {
|
|
133360
|
+
function canResolve(id, projectPath) {
|
|
133246
133361
|
try {
|
|
133247
|
-
return require.resolve(id
|
|
133362
|
+
return require.resolve(id, {
|
|
133363
|
+
paths: getResolutionPaths(projectPath)
|
|
133364
|
+
});
|
|
133248
133365
|
} catch {
|
|
133249
133366
|
return;
|
|
133250
133367
|
}
|
|
133251
133368
|
}
|
|
133252
133369
|
async function preflightOptionalDependencies(projectStructure, mode, opts) {
|
|
133253
|
-
const { packageJsonDir } = (0,
|
|
133370
|
+
const { packageJsonDir } = (0, webpack_lib_paths.fu)(projectStructure);
|
|
133254
133371
|
const projectPath = packageJsonDir;
|
|
133255
133372
|
if (hasPreflightMarker(projectPath)) {
|
|
133256
133373
|
if ('true' === process.env.EXTENSION_AUTHOR_MODE) console.log(`${external_pintor_default().brightMagenta('►►► Author says')} Optional deps preflight skipped (cache hit).`);
|
|
@@ -133266,67 +133383,76 @@ var __webpack_exports__ = {};
|
|
|
133266
133383
|
const usesSass = (0, sass.fZ)(projectPath);
|
|
133267
133384
|
const usesLess = (0, less.K)(projectPath);
|
|
133268
133385
|
const usesPostCss = (0, postcss.A)(projectPath);
|
|
133269
|
-
if (usesTypeScript
|
|
133270
|
-
|
|
133271
|
-
|
|
133386
|
+
if (usesTypeScript) {
|
|
133387
|
+
if (!canResolveFromProject("typescript", projectPath)) {
|
|
133388
|
+
missingOptionalDeps.add("typescript");
|
|
133389
|
+
usedIntegrations.push('TypeScript');
|
|
133390
|
+
}
|
|
133272
133391
|
}
|
|
133273
133392
|
if (usesReact) {
|
|
133274
|
-
if (!canResolve('react-refresh')) missingOptionalDeps.add('react-refresh');
|
|
133275
|
-
if (!canResolve('@rspack/plugin-react-refresh')) missingOptionalDeps.add('@rspack/plugin-react-refresh');
|
|
133393
|
+
if (!canResolve('react-refresh', projectPath)) missingOptionalDeps.add('react-refresh');
|
|
133394
|
+
if (!canResolve('@rspack/plugin-react-refresh', projectPath)) missingOptionalDeps.add('@rspack/plugin-react-refresh');
|
|
133276
133395
|
usedIntegrations.push('React');
|
|
133277
133396
|
}
|
|
133278
133397
|
if (usesPreact) {
|
|
133279
|
-
if (!canResolve('@prefresh/core')) missingOptionalDeps.add('@prefresh/core');
|
|
133280
|
-
if (!canResolve('@prefresh/utils')) missingOptionalDeps.add('@prefresh/utils');
|
|
133281
|
-
if (!canResolve('@rspack/plugin-preact-refresh')) missingOptionalDeps.add('@rspack/plugin-preact-refresh');
|
|
133282
|
-
if (!canResolve('preact')) missingOptionalDeps.add('preact');
|
|
133398
|
+
if (!canResolve('@prefresh/core', projectPath)) missingOptionalDeps.add('@prefresh/core');
|
|
133399
|
+
if (!canResolve('@prefresh/utils', projectPath)) missingOptionalDeps.add('@prefresh/utils');
|
|
133400
|
+
if (!canResolve('@rspack/plugin-preact-refresh', projectPath)) missingOptionalDeps.add('@rspack/plugin-preact-refresh');
|
|
133401
|
+
if (!canResolve('preact', projectPath)) missingOptionalDeps.add('preact');
|
|
133283
133402
|
usedIntegrations.push('Preact');
|
|
133284
133403
|
}
|
|
133285
133404
|
if (usesVue) {
|
|
133286
|
-
if (!canResolve('vue-loader')) missingOptionalDeps.add('vue-loader');
|
|
133287
|
-
if (!canResolve('@vue/compiler-sfc')) missingOptionalDeps.add('@vue/compiler-sfc');
|
|
133405
|
+
if (!canResolve('vue-loader', projectPath)) missingOptionalDeps.add('vue-loader');
|
|
133406
|
+
if (!canResolve('@vue/compiler-sfc', projectPath)) missingOptionalDeps.add('@vue/compiler-sfc');
|
|
133288
133407
|
usedIntegrations.push('Vue');
|
|
133289
133408
|
}
|
|
133290
133409
|
if (usesSvelte) {
|
|
133291
|
-
if (!canResolveFromProject('svelte-loader', projectPath) && !canResolve('svelte-loader')) missingOptionalDeps.add('svelte-loader');
|
|
133410
|
+
if (!canResolveFromProject('svelte-loader', projectPath) && !canResolve('svelte-loader', projectPath)) missingOptionalDeps.add('svelte-loader');
|
|
133292
133411
|
if (!canResolveFromProject("typescript", projectPath)) missingOptionalDeps.add("typescript");
|
|
133293
133412
|
usedIntegrations.push('Svelte');
|
|
133294
133413
|
}
|
|
133295
|
-
if (usesSass
|
|
133296
|
-
|
|
133297
|
-
|
|
133298
|
-
|
|
133299
|
-
|
|
133300
|
-
|
|
133301
|
-
|
|
133302
|
-
|
|
133303
|
-
|
|
133414
|
+
if (usesSass) {
|
|
133415
|
+
if (!canResolve('sass-loader', projectPath)) {
|
|
133416
|
+
const postCssDeps = [
|
|
133417
|
+
'postcss-loader',
|
|
133418
|
+
'postcss-scss',
|
|
133419
|
+
'postcss-preset-env'
|
|
133420
|
+
];
|
|
133421
|
+
for (const dep of postCssDeps)if (!canResolve(dep, projectPath)) missingOptionalDeps.add(dep);
|
|
133422
|
+
missingOptionalDeps.add('sass-loader');
|
|
133423
|
+
usedIntegrations.push('Sass');
|
|
133424
|
+
}
|
|
133304
133425
|
}
|
|
133305
|
-
if (usesLess
|
|
133306
|
-
if (!canResolve('less'))
|
|
133307
|
-
|
|
133308
|
-
|
|
133426
|
+
if (usesLess) {
|
|
133427
|
+
if (!canResolve('less-loader', projectPath)) {
|
|
133428
|
+
if (!canResolve('less', projectPath)) missingOptionalDeps.add('less');
|
|
133429
|
+
missingOptionalDeps.add('less-loader');
|
|
133430
|
+
usedIntegrations.push('Less');
|
|
133431
|
+
}
|
|
133309
133432
|
}
|
|
133310
|
-
if (usesPostCss
|
|
133311
|
-
if (
|
|
133433
|
+
if (!usesPostCss || canResolve('postcss-loader', projectPath) || usesSass || usesLess) {
|
|
133434
|
+
if (usesPostCss) usedIntegrations.push('PostCSS');
|
|
133435
|
+
} else {
|
|
133436
|
+
if (!canResolve('postcss', projectPath)) missingOptionalDeps.add('postcss');
|
|
133312
133437
|
missingOptionalDeps.add('postcss-loader');
|
|
133313
133438
|
usedIntegrations.push('PostCSS');
|
|
133314
133439
|
}
|
|
133315
133440
|
if (missingOptionalDeps.size > 0) {
|
|
133316
133441
|
const uniqueIntegrations = Array.from(new Set(usedIntegrations));
|
|
133317
133442
|
await (0, integrations.Dy)('Optional', Array.from(missingOptionalDeps), uniqueIntegrations);
|
|
133318
|
-
if (opts?.showRunAgainMessage !== false) console.log(js_frameworks_lib_messages.Q2(uniqueIntegrations));
|
|
133443
|
+
if (opts?.showRunAgainMessage !== false && 'true' === process.env.EXTENSION_AUTHOR_MODE) console.log(js_frameworks_lib_messages.Q2(uniqueIntegrations));
|
|
133319
133444
|
if (opts?.exitOnInstall !== false) process.exit(0);
|
|
133320
133445
|
}
|
|
133321
133446
|
writePreflightMarker(projectPath);
|
|
133322
133447
|
}
|
|
133323
133448
|
function shouldRunOptionalPreflight(projectStructure) {
|
|
133324
|
-
const { packageJsonDir } = (0,
|
|
133449
|
+
const { packageJsonDir } = (0, webpack_lib_paths.fu)(projectStructure);
|
|
133325
133450
|
const projectPath = packageJsonDir;
|
|
133326
|
-
|
|
133451
|
+
if (hasPreflightMarker(projectPath)) return false;
|
|
133452
|
+
return true;
|
|
133327
133453
|
}
|
|
133328
133454
|
async function ensureProjectReady(projectStructure, mode, opts) {
|
|
133329
|
-
const { packageJsonDir } = (0,
|
|
133455
|
+
const { packageJsonDir } = (0, webpack_lib_paths.fu)(projectStructure);
|
|
133330
133456
|
const result = await ensureDependencies(packageJsonDir, opts);
|
|
133331
133457
|
if (shouldRunOptionalPreflight(projectStructure)) await preflightOptionalDependencies(projectStructure, mode, {
|
|
133332
133458
|
exitOnInstall: opts?.exitOnInstall
|
|
@@ -133337,8 +133463,8 @@ var __webpack_exports__ = {};
|
|
|
133337
133463
|
const projectStructure = await getProjectStructure(pathOrRemoteUrl);
|
|
133338
133464
|
const isVitest = 'true' === process.env.VITEST;
|
|
133339
133465
|
const shouldExitOnError = (buildOptions?.exitOnError ?? true) && !isVitest;
|
|
133340
|
-
const browser = (0,
|
|
133341
|
-
const { manifestDir, packageJsonDir } = (0,
|
|
133466
|
+
const browser = (0, webpack_lib_paths.YN)(buildOptions?.browser || 'chrome', buildOptions?.chromiumBinary, buildOptions?.geckoBinary || buildOptions?.firefoxBinary);
|
|
133467
|
+
const { manifestDir, packageJsonDir } = (0, webpack_lib_paths.fu)(projectStructure);
|
|
133342
133468
|
const isAuthor = 'true' === process.env.EXTENSION_AUTHOR_MODE;
|
|
133343
133469
|
try {
|
|
133344
133470
|
const shouldInstallProjectDeps = !isAuthor || buildOptions?.install !== false;
|
|
@@ -133359,7 +133485,7 @@ var __webpack_exports__ = {};
|
|
|
133359
133485
|
const debug = isAuthor;
|
|
133360
133486
|
if (projectStructure.packageJsonPath) assertNoManagedDependencyConflicts(projectStructure.packageJsonPath, manifestDir);
|
|
133361
133487
|
const commandConfig = await (0, config_loader.eY)(manifestDir, 'build');
|
|
133362
|
-
const distPath = (0,
|
|
133488
|
+
const distPath = (0, webpack_lib_paths.q4)(packageJsonDir, browser);
|
|
133363
133489
|
if (debug) {
|
|
133364
133490
|
console.log(messages.SG(manifestDir, packageJsonDir));
|
|
133365
133491
|
console.log(messages._A(browser, buildOptions?.chromiumBinary, buildOptions?.geckoBinary || buildOptions?.firefoxBinary));
|
|
@@ -133602,7 +133728,7 @@ export {}
|
|
|
133602
133728
|
try {
|
|
133603
133729
|
const isAuthor = 'true' === process.env.EXTENSION_AUTHOR_MODE;
|
|
133604
133730
|
const debug = isAuthor;
|
|
133605
|
-
const { manifestDir, packageJsonDir } = (0,
|
|
133731
|
+
const { manifestDir, packageJsonDir } = (0, webpack_lib_paths.fu)(projectStructure);
|
|
133606
133732
|
const shouldInstallProjectDeps = !isAuthor || false !== devOptions.install;
|
|
133607
133733
|
await ensureProjectReady(projectStructure, 'development', {
|
|
133608
133734
|
skipProjectInstall: !projectStructure.packageJsonPath || !shouldInstallProjectDeps,
|
|
@@ -133611,7 +133737,7 @@ export {}
|
|
|
133611
133737
|
});
|
|
133612
133738
|
if ((0, typescript.eE)(manifestDir)) await generateExtensionTypes(manifestDir, packageJsonDir);
|
|
133613
133739
|
if (projectStructure.packageJsonPath) assertNoManagedDependencyConflicts(projectStructure.packageJsonPath, manifestDir);
|
|
133614
|
-
const browser = (0,
|
|
133740
|
+
const browser = (0, webpack_lib_paths.YN)(devOptions.browser || 'chrome', devOptions.chromiumBinary, devOptions.geckoBinary || devOptions.firefoxBinary);
|
|
133615
133741
|
const geckoBinary = devOptions.geckoBinary || devOptions.firefoxBinary;
|
|
133616
133742
|
if (debug) {
|
|
133617
133743
|
console.log(messages.SG(manifestDir, packageJsonDir));
|
|
@@ -133718,10 +133844,10 @@ export {}
|
|
|
133718
133844
|
const projectStructure = await getProjectStructure(pathOrRemoteUrl);
|
|
133719
133845
|
const debug = 'true' === process.env.EXTENSION_AUTHOR_MODE;
|
|
133720
133846
|
if (projectStructure.packageJsonPath) assertNoManagedDependencyConflicts(projectStructure.packageJsonPath, external_path_.dirname(projectStructure.manifestPath));
|
|
133721
|
-
const { manifestDir, packageJsonDir } = (0,
|
|
133722
|
-
const browser = (0,
|
|
133723
|
-
const outputPath = (0,
|
|
133724
|
-
const distPath = (0,
|
|
133847
|
+
const { manifestDir, packageJsonDir } = (0, webpack_lib_paths.fu)(projectStructure);
|
|
133848
|
+
const browser = (0, webpack_lib_paths.YN)(previewOptions.browser || 'chrome', previewOptions.chromiumBinary, previewOptions.geckoBinary || previewOptions.firefoxBinary);
|
|
133849
|
+
const outputPath = (0, webpack_lib_paths.u2)(projectStructure, browser, previewOptions.outputPath);
|
|
133850
|
+
const distPath = (0, webpack_lib_paths.q4)(packageJsonDir, browser);
|
|
133725
133851
|
if (debug) {
|
|
133726
133852
|
console.log(messages.SG(manifestDir, packageJsonDir));
|
|
133727
133853
|
console.log(messages._A(browser, previewOptions.chromiumBinary, previewOptions.geckoBinary || previewOptions.firefoxBinary));
|
|
@@ -133781,11 +133907,11 @@ export {}
|
|
|
133781
133907
|
exitOnInstall: false,
|
|
133782
133908
|
showRunAgainMessage: false
|
|
133783
133909
|
});
|
|
133784
|
-
const browser = (0,
|
|
133785
|
-
const { manifestDir, packageJsonDir } = (0,
|
|
133910
|
+
const browser = (0, webpack_lib_paths.YN)(startOptions.browser || 'chrome', startOptions.chromiumBinary, startOptions.geckoBinary || startOptions.firefoxBinary);
|
|
133911
|
+
const { manifestDir, packageJsonDir } = (0, webpack_lib_paths.fu)(projectStructure);
|
|
133786
133912
|
const commandConfig = await (0, config_loader.eY)(packageJsonDir, 'start');
|
|
133787
133913
|
const browserConfig = await (0, config_loader.xY)(packageJsonDir, browser);
|
|
133788
|
-
const distPath = (0,
|
|
133914
|
+
const distPath = (0, webpack_lib_paths.q4)(packageJsonDir, browser);
|
|
133789
133915
|
if (debug) {
|
|
133790
133916
|
console.log(messages.SG(manifestDir, packageJsonDir));
|
|
133791
133917
|
console.log(messages._A(browser, startOptions.chromiumBinary, startOptions.geckoBinary || startOptions.firefoxBinary));
|