起因我要打包区分测试环境和线上环境的变量;想直接通过process.env中的变量区分:设置如下 "set \"VUE_APP_PACKAGE_ENV=stage\" && node build/build.js" 参考 https://zhuanlan.zhihu.com/p/359367477