部分逻辑修复

This commit is contained in:
2026-07-29 23:27:46 +08:00
parent acbab598e4
commit 74f6478e4e
+2 -1
View File
@@ -477,7 +477,8 @@ do_deploy() {
# ----- 事务前钩子:备份数据库(仅降级时备份) -----
BACKUP_DIR=""
if [ -n "$CURRENT_VERSION" ] && [ "$CURRENT_VERSION" != "0.0.0-dev" ]; then
# 仅当 CURRENT_VERSION 是有效版本格式时才进行版本比对
if [ -n "$CURRENT_VERSION" ] && [ "$CURRENT_VERSION" != "0.0.0-dev" ] && [ "$CURRENT_VERSION" != "(首次部署)" ]; then
compare_version "$CURRENT_VERSION" "$TARGET_VERSION"
COMPARE_RESULT=$?
if [ $COMPARE_RESULT -eq 2 ]; then