* [build] support to release weex-legacy-framework

Project: http://git-wip-us.apache.org/repos/asf/incubator-weex/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-weex/commit/5aa1517a
Tree: http://git-wip-us.apache.org/repos/asf/incubator-weex/tree/5aa1517a
Diff: http://git-wip-us.apache.org/repos/asf/incubator-weex/diff/5aa1517a

Branch: refs/heads/0.16-dev
Commit: 5aa1517abb1fc5d20cb65c1d3fd6fc9f13cdebba
Parents: 0d8f859
Author: Hanks <zhanghan...@gmail.com>
Authored: Tue Aug 1 19:22:48 2017 +0800
Committer: Hanks <zhanghan...@gmail.com>
Committed: Tue Aug 1 19:22:48 2017 +0800

----------------------------------------------------------------------
 .gitignore                                  |    1 +
 build/build.js                              |    1 +
 build/config.js                             |   13 +
 package.json                                |    2 +
 packages/weex-legacy-framework/.npmignore   |    4 +
 packages/weex-legacy-framework/index.js     | 5770 ++++++++++++++++++++++
 packages/weex-legacy-framework/index.min.js |    1 +
 packages/weex-legacy-framework/package.json |   22 +
 8 files changed, 5814 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-weex/blob/5aa1517a/.gitignore
----------------------------------------------------------------------
diff --git a/.gitignore b/.gitignore
index 4f1baeb..f97c1da 100644
--- a/.gitignore
+++ b/.gitignore
@@ -12,6 +12,7 @@ test/build
 weex_tmp
 coverage
 dist
+*.js.gz
 
 # Node
 logs

http://git-wip-us.apache.org/repos/asf/incubator-weex/blob/5aa1517a/build/build.js
----------------------------------------------------------------------
diff --git a/build/build.js b/build/build.js
index d3b0559..5327ac1 100644
--- a/build/build.js
+++ b/build/build.js
@@ -169,6 +169,7 @@ function build (name) {
   switch (name) {
     case 'native': pkgName = 'weex-js-framework'; break;
     case 'runtime': pkgName = 'weex-js-runtime'; break;
+    case 'legacy': pkgName = 'weex-legacy-framework'; break;
     case 'browser': pkgName = 'weex-web-render'; break;
     case 'vue': pkgName = 'weex-vue-render'; break;
     case 'vue-plugins': pkgName = 'weex-vue-render-plugins'; break;

http://git-wip-us.apache.org/repos/asf/incubator-weex/blob/5aa1517a/build/config.js
----------------------------------------------------------------------
diff --git a/build/config.js b/build/config.js
index 62cb4f5..f422a58 100644
--- a/build/config.js
+++ b/build/config.js
@@ -63,6 +63,19 @@ const configs = {
       }),
     ]
   },
+  'weex-legacy-framework': {
+    moduleName: 'WeexVanillaFramework',
+    entry: absolute('html5/frameworks/legacy/index.js'),
+    dest: absolute('packages/weex-legacy-framework/index.js'),
+    banner: `/* 'WEEX VANILLA FRAMEWORK ${subversion.framework}, Build 
${now()}. */\n`,
+    format: 'umd',
+    plugins: [
+      nodeResolve({
+        jsnext: true,
+        main: true
+      }),
+    ]
+  },
   'weex-web-render': {
     moduleName: 'Weex',
     entry: absolute('html5/render/browser/index.js'),

http://git-wip-us.apache.org/repos/asf/incubator-weex/blob/5aa1517a/package.json
----------------------------------------------------------------------
diff --git a/package.json b/package.json
index 68e5ab1..7e27a7e 100644
--- a/package.json
+++ b/package.json
@@ -40,6 +40,7 @@
     "postinstall": "bash ./scripts/install-hooks.sh",
     "build:native": "node build/build.js native",
     "build:runtime": "node build/build.js runtime",
+    "build:legacy": "node build/build.js legacy",
     "install:buildtools": "npm i webpack@^1.0 weex-vue-bundle-util rollup 
rollup-watch rollup-plugin-buble rollup-plugin-json rollup-plugin-eslint 
rollup-plugin-commonjs rollup-plugin-flow rollup-plugin-flow-no-whitespace 
rollup-plugin-postcss rollup-plugin-replace rollup-plugin-uglify 
rollup-plugin-node-resolve wwp flow-bin babel-core babel-eslint babel-istanbul 
babel-loader babel-plugin-coverage babel-preset-es2015 babel-runtime 
eslint-plugin-flowtype",
     "build:source": "npm run build:native && npm run build:browser && node 
build/build.js vue",
     "build:browser": "wwp && node build/build.js browser",
@@ -62,6 +63,7 @@
     "dist": "npm run dist:browser && npm run dist:vue",
     "dev:native": "node build/build.js native --watch",
     "dev:runtime": "node build/build.js runtime --watch",
+    "dev:legacy": "node build/build.js legacy --watch",
     "dev:browser": "wwp && node build/build.js native --watch",
     "dev:vue": "node build/build.js vue --watch",
     "dev:examples": "webpack --watch --config 
build/webpack.examples.config.js",

http://git-wip-us.apache.org/repos/asf/incubator-weex/blob/5aa1517a/packages/weex-legacy-framework/.npmignore
----------------------------------------------------------------------
diff --git a/packages/weex-legacy-framework/.npmignore 
b/packages/weex-legacy-framework/.npmignore
new file mode 100644
index 0000000..1cb6dac
--- /dev/null
+++ b/packages/weex-legacy-framework/.npmignore
@@ -0,0 +1,4 @@
+node_modules
+package-lock.json
+*.log
+*.gz

Reply via email to