@aiot-toolkit/aiotpack 2.0.5-beta.20 → 2.0.5-beta.22
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.
|
@@ -166,7 +166,8 @@ class UxAfterCompile {
|
|
|
166
166
|
projectPath,
|
|
167
167
|
sourceRoot,
|
|
168
168
|
outputPath,
|
|
169
|
-
completeFeature
|
|
169
|
+
completeFeature,
|
|
170
|
+
startPage
|
|
170
171
|
} = compilerOption;
|
|
171
172
|
const content = _UxFileUtils.default.getManifestInfo(projectPath, sourceRoot);
|
|
172
173
|
const translateCache = context.translateCache;
|
|
@@ -177,6 +178,15 @@ class UxAfterCompile {
|
|
|
177
178
|
content.packageInfo = _ZipUtil.default.createComment(compilerOption);
|
|
178
179
|
}
|
|
179
180
|
|
|
181
|
+
// 如果有startPage,且feature中没有router,则添加router
|
|
182
|
+
const routerFeature = 'system.router';
|
|
183
|
+
if (startPage && !content.features?.find(item => item.name === routerFeature)) {
|
|
184
|
+
content.features = content.features || [];
|
|
185
|
+
content.features.push({
|
|
186
|
+
name: routerFeature
|
|
187
|
+
});
|
|
188
|
+
}
|
|
189
|
+
|
|
180
190
|
// feature
|
|
181
191
|
if (translateCache?.featureCache.size) {
|
|
182
192
|
// 消息提示
|
|
@@ -42,6 +42,6 @@ function compareFiles(filePath1, filePath2) {
|
|
|
42
42
|
}
|
|
43
43
|
function computeFileHash(filePath) {
|
|
44
44
|
const fileData = _fs.default.readFileSync(filePath);
|
|
45
|
-
const hash = (0, _crypto.createHash)('
|
|
45
|
+
const hash = (0, _crypto.createHash)('SHA256').update(fileData);
|
|
46
46
|
return hash.digest('hex');
|
|
47
47
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@aiot-toolkit/aiotpack",
|
|
3
|
-
"version": "2.0.5-beta.
|
|
3
|
+
"version": "2.0.5-beta.22",
|
|
4
4
|
"description": "The process tool for packaging aiot projects.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"aiotpack"
|
|
@@ -19,14 +19,14 @@
|
|
|
19
19
|
"test": "node ./__tests__/aiotpack.test.js"
|
|
20
20
|
},
|
|
21
21
|
"dependencies": {
|
|
22
|
-
"@aiot-toolkit/generator": "2.0.5-beta.
|
|
23
|
-
"@aiot-toolkit/parser": "2.0.5-beta.
|
|
24
|
-
"@aiot-toolkit/shared-utils": "2.0.5-beta.
|
|
22
|
+
"@aiot-toolkit/generator": "2.0.5-beta.22",
|
|
23
|
+
"@aiot-toolkit/parser": "2.0.5-beta.22",
|
|
24
|
+
"@aiot-toolkit/shared-utils": "2.0.5-beta.22",
|
|
25
25
|
"@hap-toolkit/aaptjs": "^2.0.0",
|
|
26
26
|
"@rspack/core": "^1.3.9",
|
|
27
27
|
"aiot-parse5": "^1.0.2",
|
|
28
28
|
"babel-loader": "^9.1.3",
|
|
29
|
-
"file-lane": "2.0.5-beta.
|
|
29
|
+
"file-lane": "2.0.5-beta.22",
|
|
30
30
|
"file-loader": "^6.2.0",
|
|
31
31
|
"fs-extra": "^11.2.0",
|
|
32
32
|
"hap-toolkit": "^2.0.0",
|
|
@@ -43,5 +43,5 @@
|
|
|
43
43
|
"@types/jsrsasign": "^10.5.12",
|
|
44
44
|
"@types/webpack-sources": "^3.2.3"
|
|
45
45
|
},
|
|
46
|
-
"gitHead": "
|
|
46
|
+
"gitHead": "cb8b82107dd1d8e977a529fcd334095627bd5d7c"
|
|
47
47
|
}
|