@winner-fed/winner-deploy 2.0.10 → 2.0.11
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -0
- package/package.json +1 -1
- package/src/winner-deploy.js +5 -2
package/README.md
CHANGED
package/package.json
CHANGED
package/src/winner-deploy.js
CHANGED
|
@@ -139,12 +139,15 @@ exports.generateSeePackageZip = function generateSeePackageZip ({
|
|
|
139
139
|
// 不包含在 manifest.json 配置的文件,直接拷贝到 see 包里
|
|
140
140
|
if (Array.isArray(copyFiles) && copyFiles.length) {
|
|
141
141
|
copyFiles.forEach((file) => {
|
|
142
|
-
|
|
142
|
+
// 1. 首先先确保文件目录存在,否则创建
|
|
143
|
+
fs.ensureFileSync(`./tmp/source/${name}/${file}`)
|
|
144
|
+
// 2. 然后进行拷贝
|
|
145
|
+
fs.copyFileSync(`./dist/${name}/${file}`, `./tmp/source/${name}/${file}`)
|
|
143
146
|
});
|
|
144
147
|
}
|
|
145
148
|
|
|
146
149
|
// 自定义执行的操作
|
|
147
|
-
typeof cb === 'function' && cb()
|
|
150
|
+
typeof cb === 'function' && cb()
|
|
148
151
|
|
|
149
152
|
done()
|
|
150
153
|
console.log()
|