Ver código fonte

已完成!移除了 Jenkinsfile 中的 "更新子模块" stage,并调整了进度百分比:

- 移除了 `stage('更新子模块')` (原第 177-198 行)
- 调整进度: 依赖安装 40% → 35%,配置文件检查 55% → 50%

现在的 pipeline stages:
1. 初始化 (0%)
2. 代码拉取 (20%)
3. 依赖安装 (35%)
4. 生成配置文件 (50%)
5. 项目构建 (70%)
6. Cloudflare 部署 (100%)
yb 3 semanas atrás
pai
commit
fa4c1b833e
1 arquivos alterados com 2 adições e 25 exclusões
  1. 2 25
      Jenkinsfile

+ 2 - 25
Jenkinsfile

@@ -174,29 +174,6 @@ pipeline {
             }
         }
 
-        stage('更新子模块') {
-            steps {
-                script {
-                    sh '''
-                        source ${WORKSPACE}/jenkins/lib/logger.sh
-                        source ${WORKSPACE}/jenkins/lib/telegram.sh
-
-                        log_message "检查并更新 Git 子模块"
-
-                        if [ -f ".gitmodules" ]; then
-                            log_message "发现 .gitmodules,开始更新子模块"
-                            git submodule update --init --recursive
-                            log_message "子模块更新完成"
-                        else
-                            log_message "没有子模块,跳过"
-                        fi
-
-                        update_progress 30 "子模块更新完成"
-                    '''
-                }
-            }
-        }
-
         stage('依赖安装') {
             steps {
                 script {
@@ -231,7 +208,7 @@ pipeline {
                         INSTALL_DURATION=$((INSTALL_END - INSTALL_START))
                         log_message "依赖安装完成,耗时: ${INSTALL_DURATION}秒"
 
-                        update_progress 40 "依赖安装完成"
+                        update_progress 35 "依赖安装完成"
                     '''
                 }
             }
@@ -260,7 +237,7 @@ pipeline {
 
                         log_message "配置文件检查完成"
 
-                        update_progress 55 "配置文件检查完成"
+                        update_progress 50 "配置文件检查完成"
                     '''
                 }
             }