@pisell/common 0.0.69 → 0.0.70
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/es/script/utils/index.js
CHANGED
|
@@ -172,7 +172,7 @@ var serverUnpack = function serverUnpack(conn, _ref5) {
|
|
|
172
172
|
reject(err);
|
|
173
173
|
return;
|
|
174
174
|
}
|
|
175
|
-
stream.end(" ".concat(env === 'prod' ? 'sudo -i' : '', "\n cd /tmp\n mv ").concat(fullFileName, " ").concat(path, "\n cd ").concat(path, "\n unzip ").concat(fullFileName, " -d ").concat(fileName, " && mv ").concat(fileName, "/dist/* ").concat(fileName, "/ && rmdir ").concat(fileName, "/dist\n rm -rf ").concat(fullFileName, "\n echo \"").concat(changelog, "\" > ./").concat(fileName, "/changelog.md\n sh deleteOldVersion.sh\n exit\n ").concat(env === 'prod' ? 'exit' : '', "\n ") // 打开到path
|
|
175
|
+
stream.end(" ".concat(env === 'prod' ? 'sudo -i' : '', "\n cd /tmp\n mv ").concat(fullFileName, " ").concat(path, "\n cd ").concat(path, "\n unzip ").concat(fullFileName, " -d ").concat(fileName, " && \\mv -f ").concat(fileName, "/dist/* ").concat(fileName, "/ && rmdir ").concat(fileName, "/dist\n rm -rf ").concat(fullFileName, "\n echo \"").concat(changelog, "\" > ./").concat(fileName, "/changelog.md\n sh deleteOldVersion.sh\n exit\n ").concat(env === 'prod' ? 'exit' : '', "\n ") // 打开到path
|
|
176
176
|
// 解压 1.0.0.zip 文件到 1.0.0 移动dist中内容到 1.0.0内 删除dist
|
|
177
177
|
// 删除1.0.0.zip
|
|
178
178
|
// 写入changelog到changelog.md
|
|
@@ -130,7 +130,7 @@ var serverUnpack = (conn, { path: path2, fileName, fullFileName, changelog, env
|
|
|
130
130
|
cd /tmp
|
|
131
131
|
mv ${fullFileName} ${path2}
|
|
132
132
|
cd ${path2}
|
|
133
|
-
unzip ${fullFileName} -d ${fileName} && mv ${fileName}/dist/* ${fileName}/ && rmdir ${fileName}/dist
|
|
133
|
+
unzip ${fullFileName} -d ${fileName} && \\mv -f ${fileName}/dist/* ${fileName}/ && rmdir ${fileName}/dist
|
|
134
134
|
rm -rf ${fullFileName}
|
|
135
135
|
echo "${changelog}" > ./${fileName}/changelog.md
|
|
136
136
|
sh deleteOldVersion.sh
|