You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@echarts.apache.org by su...@apache.org on 2020/11/11 12:34:23 UTC

[incubator-echarts] branch fix/release-fix created (now 93184b5)

This is an automated email from the ASF dual-hosted git repository.

sushuang pushed a change to branch fix/release-fix
in repository https://gitbox.apache.org/repos/asf/incubator-echarts.git.


      at 93184b5  fix: ensure folder exist for i18n build.

This branch includes the following new commits:

     new 93184b5  fix: ensure folder exist for i18n build.

The 1 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.



---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For additional commands, e-mail: commits-help@echarts.apache.org


[incubator-echarts] 01/01: fix: ensure folder exist for i18n build.

Posted by su...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

sushuang pushed a commit to branch fix/release-fix
in repository https://gitbox.apache.org/repos/asf/incubator-echarts.git

commit 93184b5066e2037aa244417ba24cdf59fb506ef8
Author: 100pah <su...@gmail.com>
AuthorDate: Wed Nov 11 20:31:34 2020 +0800

    fix: ensure folder exist for i18n build.
---
 build/build-i18n.js | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/build/build-i18n.js b/build/build-i18n.js
index 6932c74..32a408d 100644
--- a/build/build-i18n.js
+++ b/build/build-i18n.js
@@ -22,6 +22,7 @@ const fs = require('fs');
 const preamble = require('./preamble');
 const ts = require('typescript');
 const path = require('path');
+const fsExtra = require('fs-extra');
 
 const umdWrapperHead = `
 ${preamble.js}
@@ -98,6 +99,8 @@ async function buildI18nWrap() {
         const outputCode = code.replace(/export\s+?default/, 'var localeObj =')
             .replace(/\/\*([\w\W]*?)\*\//, '');
 
+        fsExtra.ensureDirSync(targetDir);
+
         fs.writeFileSync(path.join(targetDir, fileName + '.js'), umdWrapperHeadWithEcharts + outputCode + echartsRegister + umdWrapperTail, 'utf-8');
         fs.writeFileSync(path.join(targetDir, fileName + '-obj.js'), umdWrapperHead + outputCode + pureExports + umdWrapperTail, 'utf-8');
     })


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For additional commands, e-mail: commits-help@echarts.apache.org