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

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

commit 1cdcb87db21bbd1aac5a99a2885eb478eb2dd713
Author: sushuang <[email protected]>
AuthorDate: Thu Sep 12 21:55:04 2019 +0800

    fix(build): add more instructions about "how to build source code".
---
 README.md    | 29 +++++++++++++++++++++++++++--
 package.json |  3 +++
 2 files changed, 30 insertions(+), 2 deletions(-)

diff --git a/README.md b/README.md
index ebcb9fd..bb2fddd 100644
--- a/README.md
+++ b/README.md
@@ -52,8 +52,33 @@ ECharts-GL is an extension pack of ECharts, which provides 
3D plots, globe visua
 
 ## Build
 
-Check this tutorial [Create Custom Build of 
ECharts](https://echarts.apache.org/en/tutorial.html#Create%20Custom%20Build%20of%20ECharts)
- please.
+Build echarts source code:
+
+Execute the instructions in the root directory of the echarts:
+([Node.js](https://nodejs.org) is required)
+
+```shell
+# Install the dependencies from NPM:
+npm install
+
+# If intending to build and get all types of the "production" files:
+node build/build.js --release
+
+# If only intending to get `dist/echarts.js`, which is usually
+# enough in dev or running the tests:
+node build/build.js
+
+# Get the same "production" files as `node build/build.js`, while
+# watching the editing of the source code. Usually used in dev.
+node build/build.js -w
+
+# Check the manual:
+node build/build.js --help
+```
+
+Then the "production" files are generated in `dist` directory.
+
+More custom build approaches can be checked in this tutorial: [Create Custom 
Build of 
ECharts](https://echarts.apache.org/en/tutorial.html#Create%20Custom%20Build%20of%20ECharts)
 please.
 
 ## Contribution
 
diff --git a/package.json b/package.json
index 3efacc5..acd9c4b 100644
--- a/package.json
+++ b/package.json
@@ -13,6 +13,9 @@
     "url": "https://github.com/apache/incubator-echarts.git";
   },
   "scripts": {
+    "build": "node build/build.js",
+    "build:watch": "node build/build.js -w",
+    "build:release": "node build/build.js --release",
     "prepublish": "node build/build.js --prepublish",
     "test:visual": "node test/runTest/server.js",
     "test": "node build/build.js"


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to