@dcloudio/uni-cli-shared 3.0.0-5030420261029001 → 3.0.0-5030420261029002
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/hbx/utils.js +7 -7
- package/package.json +5 -5
package/dist/hbx/utils.js
CHANGED
|
@@ -7,14 +7,16 @@ exports.isInHBuilderX = void 0;
|
|
|
7
7
|
const path_1 = __importDefault(require("path"));
|
|
8
8
|
const uni_shared_1 = require("@dcloudio/uni-shared");
|
|
9
9
|
exports.isInHBuilderX = (0, uni_shared_1.once)(() => {
|
|
10
|
+
// 启动端应在加载编译器前传入工程类型,CLI 工程不能因 IDE 插件路径而使用内置环境。
|
|
11
|
+
if (process.env.UNI_PROJECT_TYPE === 'cli') {
|
|
12
|
+
return false;
|
|
13
|
+
}
|
|
14
|
+
// 未传工程类型时,沿用引入 HX_PLUGIN_PATHS 之前的识别及根目录初始化逻辑。
|
|
10
15
|
// 自动化测试传入了 HX_APP_ROOT(其实就是UNI_HBUILDERX_PLUGINS)
|
|
11
16
|
if (process.env.HX_APP_ROOT) {
|
|
12
17
|
process.env.UNI_HBUILDERX_PLUGINS = path_1.default.resolve(process.env.HX_APP_ROOT, 'plugins');
|
|
13
18
|
return true;
|
|
14
19
|
}
|
|
15
|
-
if (process.env.HX_PLUGIN_PATHS && process.env.UNI_HBUILDERX_PLUGINS) {
|
|
16
|
-
return true;
|
|
17
|
-
}
|
|
18
20
|
try {
|
|
19
21
|
const { name } = require(path_1.default.resolve(process.cwd(), '../about/package.json'));
|
|
20
22
|
if (name === 'about') {
|
|
@@ -25,8 +27,6 @@ exports.isInHBuilderX = (0, uni_shared_1.once)(() => {
|
|
|
25
27
|
catch (e) {
|
|
26
28
|
// console.error(e)
|
|
27
29
|
}
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
}
|
|
31
|
-
return false;
|
|
30
|
+
// 插件路径不代表工程类型;V 的独立插件布局由启动端显式传入 hbuilder。
|
|
31
|
+
return process.env.UNI_PROJECT_TYPE === 'hbuilder';
|
|
32
32
|
});
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@dcloudio/uni-cli-shared",
|
|
3
|
-
"version": "3.0.0-
|
|
3
|
+
"version": "3.0.0-5030420261029002",
|
|
4
4
|
"description": "@dcloudio/uni-cli-shared",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"types": "dist/index.d.ts",
|
|
@@ -71,9 +71,9 @@
|
|
|
71
71
|
"unimport": "4.1.1",
|
|
72
72
|
"unplugin-auto-import": "19.1.0",
|
|
73
73
|
"xregexp": "5.1.2",
|
|
74
|
-
"@dcloudio/uni-
|
|
75
|
-
"@dcloudio/uni-
|
|
76
|
-
"@dcloudio/uni-
|
|
74
|
+
"@dcloudio/uni-i18n": "3.0.0-5030420261029002",
|
|
75
|
+
"@dcloudio/uni-shared": "3.0.0-5030420261029002",
|
|
76
|
+
"@dcloudio/uni-nvue-styler": "3.0.0-5030420261029002"
|
|
77
77
|
},
|
|
78
78
|
"gitHead": "33e807d66e1fe47e2ee08ad9c59247e37b8884da",
|
|
79
79
|
"devDependencies": {
|
|
@@ -93,6 +93,6 @@
|
|
|
93
93
|
"code-frame": "link:@types/@babel/code-frame",
|
|
94
94
|
"postcss": "8.5.6",
|
|
95
95
|
"vue": "3.4.21",
|
|
96
|
-
"@dcloudio/uni-uts-v1": "3.0.0-
|
|
96
|
+
"@dcloudio/uni-uts-v1": "3.0.0-5030420261029002"
|
|
97
97
|
}
|
|
98
98
|
}
|