未验证 提交 1eaea81a 编写于 作者: S sushuang 提交者: GitHub

Merge pull request #13629 from apache/fix/build-scripts

fix(build): fix some compatibility issues of build scripts in Windows.
......@@ -37,7 +37,7 @@ function preparePlugins(
// if (zrRealPath !== zrNodeModulePath) {
// include.push(zrRealPath + '/**/*.ts');
// }
include.push(zrRealPath + '/**/*.ts');
include.push(zrRealPath + '/src/**/*.ts');
if (clean) {
console.log('Built in clean mode without cache.');
......
......@@ -311,10 +311,10 @@ function transformRootFolderInEntry(entryFile, replacement) {
* Transform `zrender/src` to `zrender/esm` in all files
*/
async function transformDistributionFiles(rooltFolder, replacement) {
const files = await globby([
rooltFolder + '/**/*.js',
rooltFolder + '/**/*.d.ts',
]);
const files = await readFilePaths({
patterns: ['**/*.js', '**/*.d.ts'],
cwd: rooltFolder
});
// Simple regex replacement
// TODO More robust way?
for (let fileName of files) {
......
......@@ -19,7 +19,7 @@
* under the License.
*/
const {spawn} = require('child_process');
const spawn = require('cross-spawn');
const path = require('path');
const chalk = require('chalk');
const fsExtra = require('fs-extra');
......@@ -78,4 +78,4 @@ function release() {
});
}
release();
\ No newline at end of file
release();
......@@ -45,7 +45,7 @@ const fullDayFormatter = '{yyyy}-{MM}-{dd}';
export const fullLeveledFormatter = {
year: '{yyyy}',
month: '{yyyy}:{MM}',
month: '{yyyy}-{MM}',
day: fullDayFormatter,
hour: fullDayFormatter + ' ' + defaultLeveledFormatter.hour,
minute: fullDayFormatter + ' ' + defaultLeveledFormatter.minute,
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册