From 360f2f40b1dcc9044884bfbe0ae7e7798059bed8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=99=88=E5=98=89=E6=B6=B5?= Date: Sat, 12 May 2018 12:30:53 +0800 Subject: [PATCH] [Build] fix package version --- build/bin/build-entry.js | 2 +- build/release.sh | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/build/bin/build-entry.js b/build/bin/build-entry.js index 6c545ac4b..e6ca9e141 100644 --- a/build/bin/build-entry.js +++ b/build/bin/build-entry.js @@ -2,7 +2,7 @@ const Components = require('./get-components')(); const fs = require('fs'); const path = require('path'); const uppercamelize = require('uppercamelcase'); -const version = require('../../package.json').version; +const version = process.env.VERSION || require('../../package.json').version; const tips = '// This file is auto gererated by build/bin/build-entry.js'; function buildVantEntry() { diff --git a/build/release.sh b/build/release.sh index cb1ef3f98..c4a7a3efd 100644 --- a/build/release.sh +++ b/build/release.sh @@ -11,7 +11,7 @@ echo # (optional) move to a new line if [[ $REPLY =~ ^[Yy]$ ]] then # build - npm run dist + VERSION=$VERSION npm run dist # publish vant-css echo "Releasing vant-css $VERSION ..."