@kengic/uni 0.6.3-beta.54 → 0.6.3-beta.56
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/package.json +1 -1
- package/script/postinstall.js +11 -4
package/package.json
CHANGED
package/script/postinstall.js
CHANGED
|
@@ -1,9 +1,16 @@
|
|
|
1
|
-
|
|
1
|
+
import fs from 'fs';
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* 获取当前时间.
|
|
5
|
+
*/
|
|
2
6
|
function now() {
|
|
3
7
|
return new Date(Date.now() + 1000 * 60 * 60 * 8).toISOString().substring(0, 23).replace('T', ' ');
|
|
4
8
|
}
|
|
5
9
|
|
|
6
|
-
console.
|
|
7
|
-
console.log(`[${now()}] [@kengic/uni] POST INSTALL 222`);
|
|
10
|
+
console.log(`[${now()}] [@kengic/uni] POST INSTALL`);
|
|
8
11
|
console.log(`[${now()}] [@kengic/uni] POST INSTALL ${process.cwd()}`);
|
|
9
|
-
|
|
12
|
+
|
|
13
|
+
const { default: json01 } = await import('../../../package.json');
|
|
14
|
+
console.log('333', json01.name);
|
|
15
|
+
|
|
16
|
+
fs.writeFileSync('../../../package.json', `${JSON.stringify(json01, null, 4)}\n`, {});
|